EDITED
I googled to write a custom regular expression for my web application, and still I can’t get what I wanted.
I want to check if a string passes this pattern or not:
*STRING*STRING INCLUDING ALL CHARS*STRING INCLUDING ALL CHARS#
for example:
*STRING*the first string تست یک*the second string تست دو#
Should return TRUE
*sdsdsd*the first string تست یکthe second string تست دو#
should return FALSE(because it’s not the pattern as *STRING*STRING*STRING#)
$check = preg_match("THE RULE", $STRING);
I’m asking for THE RULE here, sorry if I asked my question in a wrong way…
To check if a string has this pattern or not:
*STRING*STRING*STRING#:Then use
to check whether the first group might contain an e-mail address.