Forum Moderators: coopster
: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 's' , tshirts.saleslink = 'smoo', tshirts.imagelink = 'smoo' ,
sql_query = " UPDATE tshirts SET catagory = '$catagory',
shirtname = '$shirtname',
tshirts.sex = '$sex',
tshirts.size = '$size',
tshirts.colour = '$colour',
tshirts.price = '$price' ,
tshirts.material = '$material',
tshirts.salestext '$salestext',
tshirts.shortsalestext = '$shortsalestext' ,
tshirts.saleslink = '$saleslink',
tshirts.imagelink = '$imagelink',
tshirts.lastentered = '$lastentered'
WHERE tshirts.tshirtid = '$tshirtid' ";
print $sql_query;
I imagine you have an unescaped single quote in one of the entries. If so, do addslashes() to any field that 'could' have a single quote in it.
Regards,
Birdman
Refs:
[us4.php.net...]
[us4.php.net...]
sql_query = " UPDATE tshirts SET catagory = '$catagory',
shirtname = '$shirtname',
tshirts.sex = '$sex',
tshirts.size = '$size',
tshirts.colour = '$colour',
tshirts.price = '$price' ,
tshirts.material = '$material',
tshirts.salestext '$salestext',
tshirts.shortsalestext = '$shortsalestext' ,
tshirts.saleslink = '$saleslink',
tshirts.imagelink = '$imagelink',
tshirts.lastentered = '$lastentered'
WHERE tshirts.tshirtid = '$tshirtid' ";
the bold line is missing a "=".