in reply to Re: Perl copy Text from file to Script
in thread Perl copy Text from file to Script

If $file[0] = www.abcd.com and $file[1] = www.google.com. I get "www.abcd123.com" when i print $file[0] and "www.google.com" when i print $file[1]. Yes both File[0] and file[1] hold URLs. Whether I pass $file[0] to ->get( ) or $File[0] to ->get( ). I always get :

The URL is Inactive.

But if I directly pass http://www.google.com to ->get( ) I get :

The URL is active.

Replies are listed 'Best First'.
Re^3: Perl copy Text from file to Script
by almut (Canon) on Mar 22, 2010 at 09:00 UTC

    Well, there's one difference between what you pass via $file[0] and what you pass directly: the latter one has the protocol specifier "http://".  So, I would try $ua->get("http://$file[0]").