RE: [PHP] Bizarre Quotes Behavior

From: Date: Sat, 12 Apr 2003 01:45:54 +0000
Subject: RE: [PHP] Bizarre Quotes Behavior
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-143494@lists.php.net to get a copy of this message
> > On Thu, 10 Apr 2003, Mike At Spy wrote: > > > > I've got some very bizarre behavior by PHP regarding quotes. > > > > I have an interface which text is put into and with apostrophes > like: we've. > > > > It seems that when the information is pulled out of the > database, in a very > > ordinary fashion, the quotes randomly double or triple up. And then > > sometimes they don't. > > > > Meaning, I can load a page with the text from the db and sometimes I get > > this: > > > > we've. > > > > And sometimes this: > > > > we''''ve. > > What's your magic_quotes_sybase directive set to? I > am guessing it along with magic_quotes_gpc is on and > that you also addslashes() data before inserting > into the database. So, you escape ' twice. > You are right about that on both counts. If so, is there a workaround? If I have to turn off magic quotes, can I do that without having to recompile PHP? Thanks, -Mike

« previous php.general (#143494) next »