Re: Magic Quotes - Problems with Inconsistent Behavior removing Slashes
| From: | Richard Lynch | Date: | Tue, 16 Jan 2001 04:07:45 +0000 |
| Subject: | Re: Magic Quotes - Problems with Inconsistent Behavior removing Slashes | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-34757@lists.php.net to get a copy of this message | ||
Unless I'm even more confused than usual about something I've long believed
to be true...
MagicQuotes does not ever strip slashes.
MagicQuotes does an addslashes before the data gets into the database.
Are you viewing the same record all the time, or is it possible that one of
your records has an extra \ in it?
----- Original Message -----
From: Roy <royb666@earthlink.net>
Newsgroups: php.general
Sent: Monday, January 15, 2001 5:48 PM
Subject: [PHP] Magic Quotes - Problems with Inconsistent Behavior removing
Slashes
> I'm seeing strange behavior with Magic Quotes in PHP on my ISP hosted
> accounts. Basically, it's not consistently removing the escaped
backslashes
> before displaying.
>
> For instance, take the following piece database text (stored in, say, a
> character field)....
>
> It's fun to be a penguin.
>
> If I do a simple retrieve and echo on a webpage, I will get the following
> 80% of the time..
>
> It's fun to be a penguin.
>
> But, the other 20% of the time I get
>
> It\'s fun to be a penguin.
>
> There's something inconsistent about the way MagicQuotes are removed by
the
> system...it's as if the system gets "busy" or the cache gets flushed
before
> PHP gets the opportunity to unescape the single quotes.
>
> Is anyone else seeing this behavior and has any suggestions on how to make
> it work more consistent? Yes, I've been including "stripslashes" to try to
> make SURE that these slashes get removed, but that doesn't work all the
> time EITHER.
>
> Roy
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>