Something like:
my $uri = $mech->uri; my( $server ) = $url =~ m[(^http://[^/]+)/]; ... my $pdfurl = $server . $link;
Note: There probably is some way of getting the appropriate portion of the url from URI without resorting to regex, but I've never worked out how.
In reply to Re^3: Crawling Relative Links from Webpages
by BrowserUk
in thread Crawling Relative Links from Webpages
by listanand
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |