in reply to Getting a webpage through proxy
BEGIN { $ENV{http_proxy} = "http://your.proxy:port/" };
To the top of the script.