I'm trying to add [DL] tags between specific links to websites like mediafire and megaupload
currently i use this code:
$patern ='#(<a\s[^>]*href\="([^"]*(mediafire|rapidshare|megaupload|4shared|divshare|badongo|sendspace|sharebee|sendfile|filesend|kewlshare|zshare|filestube)[^"]*)"[^>]*>).*?</a>#i';
$postmsg2 = preg_replace($patern, '[DL]$2[/DL]', $postmsg);
but it will only replace links embbed with <a href="">...</a>
i would want to also replace links that doesn't have the <a href> tags
so basically i'm looking for a code that would transform
to:
thanks a lot !