$text = ereg_replace("([[:alnum:]]{2,6}://)([[:alnum:].-_])+([[:alnum:]]{2,6})+(/[[:alnum:]_-~\.])?","<a href=\"\\0\">\\0</a>", $text);
$text = ereg_replace ('[_a-zA-z0-9\-]+(\.[_a-zA-z0-9\-]+)*\@' . '[_a-zA-z0-9\-]+(\.[a-zA-z]{1,3})', '<a href="mailto:\\0">\\0</a>', $text);
They work well. The top does the links (only works if there is [url]http://[/url] or [url]ftp://[/url] or something://) and the bottom makes emails into links also.
Note though that the one for links needs a bit more added if you want variables passed after the ? 🙂
Hope that helps 🙂
- Matt