[ Team LiB ] |
![]() ![]() |
Hour 18. Working with Regular ExpressionsWhat You'll Learn in This Hour:
Regular expressions are a powerful way of examining and modifying text. They enable you to search for patterns within a string, extracting matches flexibly and precisely. Be warned that because they are more powerful, they are also slower than the more basic string function examined in Hour 8, "Working with Strings." You should use string functions, therefore, if you don't need the extra power afforded by the use of a regular expression function. PHP supports two flavors of regular expressions. It has a set of functions that emulate regular expressions as employed in Perl and a set of functions that support the more limited POSIX regular expressions. Because Perl-compatible regular expressions are the more powerful of the two, we will concentrate on them. |
[ Team LiB ] |
![]() ![]() |