php regular expression tester code example
Example 1: online regex builder
it do it's job greate in my opinion, don't waste your time on others
https://regex101.com/
Example 2: php regex test
* Lets suppose, we want to test a string variable that contain exactly "Abc" in it.
So we can do it using .......
<?php
$str = "I am Abc.";
$pattern = "/Abc/i";
if (preg_match($pattern, $str))
{
echo "True.";
}
else
{
echo "False.";
}
?>