hey everyone.
So my end goal here is that when the user does not put data into a field of a forum, that when it's submited, what ever it's current value from the mysql databse pull, remains unchanged.
Basically if the user does not change the value it should stay the same. But i have no idea how to do this.... Since i do not know when the end user is going to update there picture or not... I need it to be pulled and updated every time they hit the submit buttion.
Here is what I have so far (part of the code that retains to the update)
$picture=$_FILES['file'];
$new_des='/web/knightsofrage.net/pic/'.$file_name.'';
if($picture !="none")$mysql_des=$data[1];
else $mysql_des='http://knightsofrage.net/pic/'.$file_name.'';
$move=move_uploaded_file($file_tmp,$new_des);
$update_string=("UPDATE website SET picture_file='$mysql_des', about_me='$text' where username='$user'");
$update=mysql_query($update_string, $db);
now.. the field name is picture_link and $_FILES['file'] is the field name that was submitted.
my
if($picture !="none")$mysql_des=$data[1];
does not work.
the $data[1] is the key that is currently stored in the mysql database. Which if the user does not enter any value in $_FILES['file'] i wish the $data[1] to stay the same.
can ya help??