I got a probleme with one of my regular expression; if you can help me :
<?php
$ptn = "/[\S]*[A-Za-z0-9_-]*.*[A-Za-z0-9_-]+@[A-Za-z0-9_-]*.*[A-Za-z0-9_-]*[\S]*/";
$str = "Contact name: Wahyu van Schneppanginen Email: perm@perotozair.com ";
preg_match($ptn, $str, $matches);
print_r($matches);
?>
Howver the result is :
Array
(
[0] => Email: perm@perotozair.com
)
But I want :
Array
(
[0] => perm@perotozair.com
)
If any of you can help me I’d be glad
Thanks !
Try This :-