Re: [PHP] mysql update not working

2003-06-25 Thread Chris Sherwood
M Subject: [PHP] mysql update not working > I have the following code: > > > $sql = "UPDATE class_sub SET desc = '$catdesc', sub_cat = '$subcatname' > WHERE id='$catid'"; > echo $sql; > $sql_result = mysql_query($sql); > if (!$sql_resu

[PHP] mysql update not working

2003-06-25 Thread Steven Efurd
I have the following code: $sql = "UPDATE class_sub SET desc = '$catdesc', sub_cat = '$subcatname' WHERE id='$catid'"; echo $sql; $sql_result = mysql_query($sql); if (!$sql_result) { echo "Couldn't update record!"; echo mysql_error(); exit; } else { header("Location: ind