Re: storing single and double quote in MySQL
| From: | Eric Butera | Date: | Wed, 24 May 2006 19:14:38 +0000 |
| Subject: | Re: storing single and double quote in MySQL | ||
| References: | 1 2 3 4 5 6 7 8 9 10 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-236848@lists.php.net to get a copy of this message | ||
On 5/24/06, afan@afan.net <afan@afan.net> wrote:
if magic_quotes_gpc is On, does it add slashes in front of quotes when submit through form? Mean, if I submit in input form (text) afan's "crazy" web, after echo $_POST['record']; I'll get afan\'s \"crazy\" web. Is this because of magic_quote_gps is On?Yep! http://us2.php.net/magic_quotes "What are Magic Quotes When on, all ' (single-quote), " (double quote), \ (backslash) and NULL characters are escaped with a backslash automatically. This is identical to what addslashes() does."