September 2001
Intermediate to advanced
768 pages
32h 45m
English
int preg_match_all(string pattern, string subject, array matches, [int order])
| pattern | Regex pattern to match |
| subject | String to search using the pattern |
| matches | Array in which to store the search results |
| order | Flag specifying the ordering of results |
Finds all matches for the supplied pattern and stores them in the supplied array.
Returns:
Number of full pattern matches found
Description:
This function tries to find all the matches for the regular expression pattern in the supplied subject string. Upon a successful search, the previous contents of matches are overwritten with the search results. The matches parameter should be a valid variable, such as $matches, since the function forces it to be passed by reference.
The ...
Read now
Unlock full access