RE: [PHP-WIN] preg_match

2001-03-02 Thread James Duncan
From: Doug Brewer [mailto:[EMAIL PROTECTED]] Sent: 03 March 2001 00:33 To: James Duncan; [EMAIL PROTECTED] Subject: RE: [PHP-WIN] preg_match I'm not a regex expert, but can't you use a negated class if (preg_match ("/[^a-z]/i", $name)) { echo "has non alpha chars"

RE: [PHP-WIN] preg_match

2001-03-02 Thread Doug Brewer
I'm not a regex expert, but can't you use a negated class if (preg_match ("/[^a-z]/i", $name)) { echo "has non alpha chars"; } else { echo "all alphas"; } sorry, didn't try the above code before sending. HTH, Doug | -Original Message- | From: James Duncan [mailto:[EMAI