Re: " " in a Variable
| From: | Richard Davey | Date: | Wed, 03 Dec 2003 03:40:56 +0000 |
| Subject: | Re: " " in a Variable | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-171631@lists.php.net to get a copy of this message | ||
Hello Dimitri,
Wednesday, December 3, 2003, 3:28:19 AM, you wrote:
DM> I'm sure this is an easy fix, but how do you either prevent users from being
DM> able to input " " in a field or make it so that it doesn't affect the code?
Assuming you mean the double quote marks, and not a blank space, use
the function htmlspecialchars() to convert the double quotes into PHP
and SQL friendly HTML entities.
--
Best regards,
Richard mailto:rich@launchcode.co.uk