PDA

View Full Version : Whats wrong :S?



MrCraig
09-08-2007, 02:32 PM
Ok, ive made this thing, but the update script doesnt seem to work.. it says its updated, but it hasnt..



$habbo = htmlspecialchars($_POST[habbo]);
$furni = htmlspecialchars($_POST[furni]);
$amount = htmlspecialchars($_POST[amount]);
$comment = htmlspecialchars($_POST[comment]);
$password = htmlspecialchars($_POST[password]);
$edit = mysql_query("UPDATE trade SET habbo='$habbo', furni='$furni', amount='$amount', comment='$comment', password='$password' WHERE id = '$id'");
echo("Item Updated!");


Please post any suggestions :)

Blob
09-08-2007, 04:03 PM
Theres no $id

Eric30
09-08-2007, 07:59 PM
change


$edit = mysql_query("UPDATE trade SET habbo='$habbo', furni='$furni', amount='$amount', comment='$comment', password='$password' WHERE id = '$id'");

too


$edit = mysql_query("UPDATE trade SET habbo='$habbo', furni='$furni', amount='$amount', comment='$comment', password='$password' WHERE id = '$id'")or die("MySQL Error: <br>".mysql_error());

and post the error message

Want to hide these adverts? Register an account for free!