I've come across this kind of thing before, where say, a " or a ' from a form will break the database update. Currently this is how the code is:
Code: Select all
$history = nl2br($history);
$Update = mysql_db_query ($dbname, "UPDATE colour_history SET history=trim('$history') WHERE id='$id'");The strange bug I'm having though is breaking (ie: no update) on using < or >. But it's not that simple. I'll show you what breaks and what doesn't. Strange!!!
Code: Select all
<> (doesn't break)
<hello> (breaks)
< hello > (doesn't break)Any advice GREATLY appreciated.
Rob