I've worked on it and came up with this:
// Email Code //
$code = ereg_replace("[email="."[_a-zA-Z0-9\-]+(\.[_a-zA-Z0-9\-]+)*\@"."[_a-zA-Z0-9\-]+(\.[_a-zA-Z]{1,3})+"."]", "<a href=\"mailto:\\0\">", $code);
$code = str_replace("[/email]", "</a>", $code);
$code = str_replace("[email=", "", $code);
// URL Code //
$code = ereg_replace("[frl="."]", "<a href=\"\\0\" target=\"blank\">", $code);
$code = str_replace("[/frl]", "</a>", $code);
$code = str_replace("[frl=", "", $code);
// End Email & URL //
$code = str_replace("]", "", $code);
There is one problem though... when i made the email one by itself it all worked fine, but now that there is the url one it doesn't work, how can i make then run without making changes to each other?
What is an easy way to fix this?
P.s. after where it says <a href="" target=""> in the href is meant to be \0.. same with in the email link. and i have called the url part frl for the reason that this forum changes it..
🙂