hey there.
i need to insert some html into a feild in a database. What i've been doing is placing the html inside a variable, and then inserting the variable into the database as shown below:
$var = "
<...html code...>
";
$result = mysql_query("INSERT INTO $table set data='$var'") or die (mysql_error());
The problem is that in order to use this method, each quote (") in the html must be escaped using a slash "\". Is there a way to get html into a database without having to escape the quotes?
Also, i need to add some php to the html -t that really dosen't work!
Can anyone help me out?
Thanks in advance!