I would like to know why I am getting a "Parse error: syntax error, unexpected T_VARIABLE, expecting T_STRING" in my code, which pulls HTML off an MySQL database, replaces < and > with the entity (< ;, > ;) and inputs it into a textarea (CKEditor). Here is that section of the code:
<textarea name="editor1">
<?php
//QUERY DATABASE
$query1 = "SELECT * FROM users WHERE ID = '" . $id . "'";
$resource1 = mysql_query($query1, $database);
$result1 = mysql_fetch_assoc($resource1);
$rawcode = $result['code'];\
$code1 = str_replace("<", "<", "$rawcode");
$code = str_replace(">", ">", "$code1");
echo $code1;
?>
<!--<p>Create your page here.</p>-->
</textarea>