#44748 [NEW]: php.ini comments on magic_quotes_gpc promote bad practices

From: Date: Wed, 16 Apr 2008 19:34:47 +0000
Subject: #44748 [NEW]: php.ini comments on magic_quotes_gpc promote bad practices
Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-717@lists.php.net to get a copy of this message
From: johnston dot joshua at gmail dot com Operating system: any PHP version: Irrelevant PHP Bug Type: Documentation problem Bug description: php.ini comments on magic_quotes_gpc promote bad practices Description: ------------ The section at the top related to magic_quotes_gpc suggests addslashes() for database escaping. It should instead say to use your the escaping function that is native to your database extension. ; - magic_quotes_gpc = Off [Performance] ; Input data is no longer escaped with slashes so that it can be sent into ; SQL databases without further manipulation. Instead, you should use the ; function addslashes() on each input element you wish to send to a database. -- Edit bug report at http://bugs.php.net/?id=44748&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=44748&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=44748&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=44748&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=44748&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=44748&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=44748&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=44748&r=needscript Try newer version: http://bugs.php.net/fix.php?id=44748&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=44748&r=support Expected behavior: http://bugs.php.net/fix.php?id=44748&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=44748&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=44748&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=44748&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=44748&r=php4 Daylight Savings: http://bugs.php.net/fix.php?id=44748&r=dst IIS Stability: http://bugs.php.net/fix.php?id=44748&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=44748&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=44748&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=44748&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=44748&r=mysqlcfg

« previous php.doc.bugs (#717) next »