Posted by Chris Gorospe on 11/02/07 05:51
Salve Håkedal wrote:
> What is the best regular expression for finding urls in plain text
> files?
> (By urls I mean http://www.something.com, but also www.something.com,
> or salve@somewhere.com)
>
> Salve
The simplest way is to use the one thing they all have in common. ".com".
strstr($text,'.com');
Navigation:
[Reply to this message]
|