mgob Posted May 14, 2009 Share Posted May 14, 2009 So, I have a application that reads from a DB and needs a field to start with a quote (not escaped) it literally has to have: "values are here" in the field. I am using MDB2 / PEAR for DBI magic_quotes auto adds slashes to the submitted info from the webapp so my question is; Is the following safe to do to keep just the quotes in the DB without the slashes? $db->quote(stripslashes($content), 'text') this inserts properly with no slashes, my only concern is, is this susceptible to injection attacks or does the MDB2 quote prevent that properly? Thanks!! Link to comment https://forums.phpfreaks.com/topic/158055-pear-db-query-with-quotes-is-this-safe/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.