Hey Guys I Am Trying To Use One Regex Pattern If And Else
//$pattern = "%http://depositfiles.com/[a-z]{2}/files/[0-9-a-z-A-z]*%";
//$pattern = "%http://depositfiles.com/files/[0-9-a-z-A-z]{9}%";
i just want to use one regex pattern to match the depositfiles
$subject = 'http://depositfiles.com/files/9178jwt09 http://depositfiles.com/en/files/9178jzt09';
$pattern = '%http://depositfiles.com/files/[a-z]{2}(?=a-z]{2}/)then|(?![0-9-a-z-A-z]{9})else)%';
preg_match_all($pattern,$subject,$array);
print_r($array);
result if it works :
Array ( [0] => Array ( [0] => http://depositfiles.com/files/9178jzt09 [1]) => http://depositfiles.com/en/files/9178jzt09)
so i just need one regex pattern to define the 2 subjects thanks cheers.