Mega Code Archive

 
Categories / Php / Development
 

String matches

<?php      $string = "PHP is great!";      $pattern = "/P.P/";      if(preg_match($pattern, $string))           print("Found a match!"); ?>