I got a text: $text = "Blah... firstname.lastname@example.org
How do I get hold of the e-mail addresses: email@example.com
, ... using regex? How to do it with php?
Would this be an smart way to do it?
preg_match_all("/(\w|\.)*@\w*\.\w*/", $text, $match);
$match contains all matches, all e-mail addresses in $text. (I also want to match e-mail addresses like firstname.lastname@example.org
Thanks for any suggestions!