Hi
I have a string like http://www.google.com/news that I want to convert to something like:
"(^|\.)google\.com\/news"
Is there a perl function that does this for me? If not can anyone suggest some code? as using ~m is very hard to do, as it 'cleans' the input string after the first pass, meaning I can't do everything I want to.
Thanks
I have a string like http://www.google.com/news that I want to convert to something like:
"(^|\.)google\.com\/news"
Is there a perl function that does this for me? If not can anyone suggest some code? as using ~m is very hard to do, as it 'cleans' the input string after the first pass, meaning I can't do everything I want to.
Thanks