Remove mysql_real_escape_string - it works now with Doctrine, and it's done by default.