Forum Moderators: coopster
I need to search a string and replace relative links like
<a href="/example/example.php"> with it's absolute url with the domain of $domain so it is <a href="http://$domain/example/example.php"> The string has both absolute url's and relative url's, so I can't just add $domain to all of them.
What's the best way to do this?