In the text file, there's some links like this <a href="http://www.domain.com/link1.html">, <a href="/link1.html">, <a href="link2.html">. How to replace all links to <a href="http://www.domain.com/link1.html">, <a href="http://www.domain.com/link2.html">, <a href="http://www.domain.com/link3.html"> using regex ? Thx
How to preg_replace link like this : <a href="http://www.domain.com/link1.html"> <a href="/link1.html"> <a href="link2.html"> to <a href="http://www.domain.com/link1.html"> <a href="http://www.domain.com/link2.html"> <a href="http://www.domain.com/link3.html"> from a string parsed from a webpage.