Occasionally you have a string and you need to find the urls in it and convert them into fully functioning links. Do do this you need to useĀ this script:
$string = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]","<a href=\"\\0\">\\0</a>", $string);
I have just updated one of my scripts with this line: Twitter feed using php and add link to any urls found