Re: addslashes() || Why the multiple slashes?

From: Date: Tue, 09 Sep 2003 15:59:55 +0000
Subject: Re: addslashes() || Why the multiple slashes?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-162085@lists.php.net to get a copy of this message
CF High wrote:
why does PHP add 3 slashes to the following var: $apostrophe = "I've got an apostrophe"; $slashed = addslashes($apostrophe); echo $slashed; Result: I\\\'ve got an apostrophe. What's up with that -- why not just add a single backslash?
Do you have gpc_magic_quotes enabled? - Brad

« previous php.general (#162085) next »