PHP: Remove all hyperlinks of specific domain from text
问题 2 things: Remove all hyperlinks that point to mydomain.com & retain all other hyperlinks that do not belong to this domain. For all the other URLs that remain, grab the value between tags and show it as ID. 1. About 1st task: I have this: $str = 'I have been searching <a href="http://www.google.com">Google</a> for all the valuable information. I have also tried <a href="http://www.yahoo.com">Yahoo</a> and I finally, ended up finding it at <font size="1">My Site <a style="color:#0000ff;font