Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

PHP FILTER_VALIDATE_REGEXP Filter

PHP FILTER_VALIDATE_REGEXP Filter


PHP Filter Reference Manual Complete PHP Filter Reference Manual


Definition and Usage

The FILTER_VALIDATE_REGEXP filter validates a value against a Perl-compatible regular expression.

Possible options:


Example

array("regexp"=>"/^M(.*)/")))) ?>

The output of the code is shown below:

string(17) "Match this string"


PHP Filter Reference Manual Complete PHP Filter Reference Manual