I have a problem with some contents, which have the same link again and again, so i want to remove all duplicate links except a single, have anyone idea how to do this????
here is my code which remove all links
function anchor_remover($page) {
$filter_text = preg_replace("|<<blink>a *<blink>href=\<blink>"(.*)\">(.*)</a>|","\\2",$page);
return $filter_text;
}
add_filter('the_content', 'anchor_remover');
basically i need this for wordpress, to filter the contents and remove duplicate links should have only a single link.