List Info

Thread: note 63806 added to function.addslashes




note 63806 added to function.addslashes
user name
2006-03-31 14:27:37
in response to:

====================================
This code can be inserted somewhere in your application
(near the start):

if (get_magic_quotes_gpc()) {

 // Yes? Strip the added slashes

 $_REQUEST = array_map('stripslashes', $_REQUEST);
 $_GET = array_map('stripslashes', $_GET);
 $_POST = array_map('stripslashes', $_POST);
 $_COOKIE = array_map('stripslashes', $_COOKIE);

}
====================================

That code will fail if someone sets a control to an array
for example:

<input type='checkbox' name='id_numbers[]' />

Just thought i'd let ya know...
----
Server IP: 85.116.0.130
Probable Submitter: 194.247.248.140
----
X-Spam-Status: No, hits=3.3 required=5.0
tests=DATE_MISSING,FROM_NO_LOWER,
	HTML_MESSAGE autolearn=no version=2.64
----
Manual Page -- 
http://www.php.net/manual/en/function.addslashes.php
Edit        -- http://master.p
hp.net/note/edit/63806
Del: integrated  -- ht
tp://master.php.net/note/delete/63806/integrated
Del: useless     -- http:
//master.php.net/note/delete/63806/useless
Del: bad code    -- http
://master.php.net/note/delete/63806/bad+code
Del: spam        -- http://m
aster.php.net/note/delete/63806/spam
Del: non-english -- h
ttp://master.php.net/note/delete/63806/non-english
Del: in docs     -- http:
//master.php.net/note/delete/63806/in+docs
Del: other reasons-- http://master
.php.net/note/delete/63806
Reject      -- http://master
.php.net/note/reject/63806
Search      -- http://ma
ster.php.net/manage/user-notes.php

-- 
PHP Notes Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub
.php

note 63806 deleted from function.addslashes by philip
user name
2006-03-31 15:27:21
Note Submitter: VBAssassin (Scott Thompson) 

----

in response to:

====================================
This code can be inserted somewhere in your application
(near the start):

if (get_magic_quotes_gpc()) {

 // Yes? Strip the added slashes

 $_REQUEST = array_map('stripslashes', $_REQUEST);
 $_GET = array_map('stripslashes', $_GET);
 $_POST = array_map('stripslashes', $_POST);
 $_COOKIE = array_map('stripslashes', $_COOKIE);

}
====================================

That code will fail if someone sets a control to an array
for example:

<input type='checkbox' name='id_numbers[]' />

Just thought i'd let ya know...

-- 
PHP Notes Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub
.php

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )