This code works, but I don't understand it. It is in a source file with the extension of ".pm". I have a static variable agent that needs to be initialized prior to the first function call.
Should not I need to use the BEGIN statement so the cookie and proxy functions get called? Apparently they are getting called anyway. The begin statement just gave me syntax errors. And what is the deal with @ISA? Is that not used for inheritance? What is the descendant class here? And what does __PACKAGE__ mean? Thanks, siegfried use vars '@ISA'; @ISA = 'LWP::UserAgent'; my $agent = __PACKAGE__->new; $agent->cookie_jar(HTTP::Cookies->new(file=>"$ENV{HOME}/.lwp-cookies",autosa ve=>1)); $agent->proxy(['http'], 'http://myproxy.mycorp.com/'); # set proxy -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>