bddotnet
1-16-09, 10:39 PM
I have a database where the admin user can update information.
The form says:
<input type="text" name="ud_lastname" value="' . $row->last_name . '" id="ud_lastname">
The update code says:
//update information
$sql = "UPDATE membership09 SET ID='$ud_ID', last_name='$ud_lastname', first_name='$ud_firstname', address='$ud_address', city='$ud_city', state='$ud_state', zip='$ud_zip', phone='$ud_phone', additional='$ud_additional', email='$ud_email', membershipyr='$ud_membershipyr', new_member='$ud_newmember', type='$ud_type', amount='$ud_amount', received='$ud_received', directory='$ud_directory' WHERE last_name = '$ud_lastname' LIMIT 1";
Every field in the field list will update except last_name. I have checked the database table to make sure the field name is correct and still not able to update THAT field.
What am I missing?
The form says:
<input type="text" name="ud_lastname" value="' . $row->last_name . '" id="ud_lastname">
The update code says:
//update information
$sql = "UPDATE membership09 SET ID='$ud_ID', last_name='$ud_lastname', first_name='$ud_firstname', address='$ud_address', city='$ud_city', state='$ud_state', zip='$ud_zip', phone='$ud_phone', additional='$ud_additional', email='$ud_email', membershipyr='$ud_membershipyr', new_member='$ud_newmember', type='$ud_type', amount='$ud_amount', received='$ud_received', directory='$ud_directory' WHERE last_name = '$ud_lastname' LIMIT 1";
Every field in the field list will update except last_name. I have checked the database table to make sure the field name is correct and still not able to update THAT field.
What am I missing?