> I am starting on php, coming from Perl. One thing I really like on the way
> we can use regex in Perl is the shorthand:
>
> \w --> [a-zA_Z0-9_]
> \W --> [^a-zA_Z0-9_]
> \d --> [0-9]
> \D --> [^0-9]
> \s --> white space characters
> ...
>
> Is this shorthand handled in php?

Sure, all the preg* functions take Perl-style regular expressions like
that.  Read the manual: http://php.net/pcre

-Rasmus


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to