[Oracle] magic_quotes_gpc && magic_quotes_sybase ?

From: Date: Sun, 28 Jan 2001 09:40:31 +0000
Subject: [Oracle] magic_quotes_gpc && magic_quotes_sybase ?
Groups: php.db 
Request: Send a blank email to php-db+get-6230@lists.php.net to get a copy of this message
I'm using php/oracle for a short time now. I'm forced to work on server where the following configuration is used: php.ini: magic_quotes_gpc = on magic_quotes_runtime = off magic_quotes_sybase = off After my first INSERT into oracle with arbitrary returned from a post form I got bitten by special characters like ', " and \. They were all escaped with \, too. But this broke my INSERTS because ' needs to be escapde with ' so it looks like '' when the acutal insert happens. As far as my testing goes, no other character needs escaping, no '\' needs; just the '. Retrieving data withing SELECT results in getting back the data WITH backslashes in them. After settigns magic_quotes_sybase = on, I couldn't believe it. Everything worked; from now one only ' was escaped to '', no other character. With the first configuration, every data coming from post forms needed to be processed with the following sequence: $input = stripslashes( $input); $input = str_replace( "'", "''", $input); After activating magic_quotes_sybase, the above is not needs anymore as the are allready escaped the right way. Has someone had such troubles too, or are there better ways of doing that ? Does someone know if the following configuration magic_quotes_gpc = on magic_quotes_runtime = off magic_quotes_sybase = on has some known issues about php stability or other problems arising with it ? (I was told so without getting more in depth information why or what) thanks for sharing ideas, Markus -- Markus Fischer, http://josefine.ben.tuwien.ac.at/~mfischer/ EMail: mfischer@josefine.ben.tuwien.ac.at PGP Public Key: http://josefine.ben.tuwien.ac.at/~mfischer/C2272BD0.asc PGP Fingerprint: D3B0 DD4F E12B F911 3CE1 C2B5 D674 B445 C227 2BD0

« previous php.db (#6230) next »