View Single Post
Old 01-18-2006, 04:34 PM   #1 (permalink)
gamehead200
Code Monkey
 
gamehead200's Avatar
 
Join Date: Oct 2004
Posts: 57
gamehead200 is an unknown quantity at this point
preg_match problems

Hey guys... Been a while again...

I'm having a problem using the preg_match function in PHP 4. Basically, I'm checking to see if any of the following characters appear in whatever the user enters:

.*$?"/|\:<>

And then using an if statement to do whatever I want...

What exactly would be my if statement with the above characters and preg_match?

I'm thinking of something along the lines of:

PHP Code:
if( preg_match(/^($)/, $url2) ) {
// stuff here...

Not sure how to include those characters in the function...

Thanks.
gamehead200 is offline   Reply With Quote