Im trying to run the following code but it is giving me a strange error..
$result = $db->query("UPDATE `items`
SET `item_label`= ".$title.",
`item_quantity`=".$quantity.", `item_price`=".$price."
WHERE `item_id` = ".$_POST['id']);
If i remove the item_label
= ".$title.", from the above code it works perfectly and successfully updates the quantity and price of the given row. e.g.
$result = $db->query("UPDATE `items`
SET `item_quantity`=".$quantity.",
`item_price`=".$price."
WHERE `item_id` = ".$_POST['id']);
when I run the code containing the item_label section it fails to set the item_label. and it gives the following error message..
Unknown column 'Updated Text' in 'field list'
Now the "Updated Text" is the value of $title.
Im baffled as to how / why it is viewing this content as a column header!?
any ideas as to why this would happen?