I have blog data like:
This is foreign <a href="xyz.com">link</a>, this is my site's <a href="mysite.com">link</a> and so on.
What I want is to do is filter the links of foreign sites, i.e "<a href="xyz.com">link</a>
". So that my final output is:
This is foreign link, this is my site's <a href="mysite.com">link</a> and so on.
I tried "preg_replace" but no pattern helped.