I found this at
http://www.php.net/manual/en/regexp.reference.subpatterns.php
(?|(Sat)ur|(Sun))day
this mean (Sat) and Sun will be matched at same order
but When I test with regexbuddy it occurr a error
abt syntax
Thanks
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This should work fine with a recent version of PCRE – did you make sure to switch regexbuddy into PCRE mode?
You’ll need a pretty recent version too. My PHP 5.2.6 install is too old (PCRE 6.6 2006-02-06), while PHP 5.2.17 (8.02 2010-03-19) is fine.
This test PHP program:
Outputs this:
If your version of PCRE is too old, you’ll get this error: