Re: Magic quotes question
| From: | Chris | Date: | Tue, 25 Jan 2005 20:09:22 +0000 |
| Subject: | Re: Magic quotes question | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-207288@lists.php.net to get a copy of this message | ||
I'm not quite sure I understand you...
The theory behind that function looks sound, but are you meaning to return the value or pass it by reference and modify it?
Chris
Ben Edwards wrote:
OK. This is really confusing me. I am using the following function to handle this: function prep( &$text ) { echo get_magic_quotes_gpc()." "; if (get_magic_quotes_gpc()) { echo "mq on for $text"; return $text; } else { echo "mq off"; return addslashes($text); } } And it is not doing the assslashes but stuff like \'s is still being added. wonce savein a few times I get \\\\\'. Ben