note 46123 added to function.stripslashes
| From: | pasamioATsirdurkusDOTnet at osu1 dot php dot net | Date: | Wed, 29 Sep 2004 23:55:46 +0000 |
| Subject: | note 46123 added to function.stripslashes | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-77600@lists.php.net to get a copy of this message | ||
If your trying to pull out some variables from $_REQUEST and directly output them (in my case,
quoted text from a search query directly into a HTML text box) with magic_quotes_gpc on use:
htmlspecialchars(stripslashes($searchtext));
For example:
<input type="Text" name="searchtext" value="<?php echo
htmlspecialchars(stripslashes($searchtext)); ?>"><br>
$searchtext was pulled from the $_REQUEST variable where $searchtext = "lifeline \"darling
downs\""; It properly returns this (including quotes) in the text box.
----
Manual Page -- http://www.php.net/manual/en/function.stripslashes.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+46123
Delete -- http://master.php.net/manage/user-notes.php?action=delete+46123&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+46123&report=yes
Search -- http://master.php.net/manage/user-notes.php