Re: Regular Expressions?
| From: | John Nichel | Date: | Sat, 09 Apr 2005 02:35:34 +0000 |
| Subject: | Re: Regular Expressions? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-212690@lists.php.net to get a copy of this message | ||
list_php_general@controlaircorp.com wrote:
<snip>
Joe's Crabshack The ' apostrophe or " can cause an early truncation of the data. My code thinks that the closing identifier is after the word Joe and the rest of the input is lost. Further, if the data does get by and it could possibly break a SQL statement. Am I right in thinking the solution in this matter is using regular expressions? If so, where is a good resource to polish my skills? What about turning off/on magic quotes? JohnNo need for a regex. Use something like mysql_escape_string() or addslashes(). That's what these functions are made for. The Camel book is a good place to start your regex learning. -- By-Tor.com ...it's all about the Rush http://www.by-tor.com