<pre>
Hi,
Could you tell me how to change www.yyy.zzz to <a href="http://www.yyy.zzz">. I tried this, but it only works with the first URL the second one won't be linked:
$text = ereg_replace(" (www.[])", " http://\1",$text);
$text = ereg_replace("((ftp://)|(http://))(([[:alnum:]]|[[:punct:]])*)", "<a href=\"\0\" target=\"_blank\">\0</a>",$text);
This changes also http://xxx.yyy.zzz URLs to hyperlinks. http://xxx.yyy.zzz conversion works perfectly, but www.yyy.zzz conversion won't.
Another problem that I have is allmost similar:
$text = ereg_replace(";b([]);b", "<b>\1</b>", $text);
This will turn all between ;b and ;b to bold, but if I have more than one pair of ;b ;b tags, it won't work like it should.
-Sami Sipponen
</pre>