note 54837 added to security.magicquotes

From: Date: Sun, 17 Jul 2005 02:44:12 +0000
Subject: note 54837 added to security.magicquotes
Groups: php.notes 
Request: Send a blank email to php-notes+get-92065@lists.php.net to get a copy of this message
Bright minds will have noticed, that one uses stripslashes() once on the input and saves that content for further processing. Then use addslashes() once before sending the content to the database or flat file. Hint: if the application is using a MySql database, don't use addslashes() but mysql_real_escape_string(). ---- Manual Page -- http://www.php.net/manual/en/security.magicquotes.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+54837 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+54837&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+54837&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+54837&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+54837&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+54837&report=yes&reason=non-english Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+54837&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+54837&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#92065) next »