Page 1 of 1

Hidden

Posted: Fri Mar 14, 2003 7:24 am
by silgol
It wanted to know as step a variable hides (that it is the key of a
table) to update the modified registries?

Posted: Sun Mar 16, 2003 5:28 am
by Gen-ik
I'm not completely sure what you mean, but if your are asking how to update information in a mysql database then you don't need keys. All you need to know is the name of the information you want to update.

Let's say you have a simple table called INFO with NAME AGE EMAIL

If you wanted to update the EMAIL you can do something like this...

$newEmail is the new email address.. and $whosEmail is the NAME of the person whos email you want to update.. then use.....

Code: Select all

<?php
mysql_query(" UPDATE `info` SET `email`='$newEmail' WHERE `name`='$whosEmail' ");
?>
Hope this helps.