use HTTP::Request::Common qw(POST); use LWP::UserAgent; use strict; my $ua = LWP::UserAgent->new(); my $req = POST 'http://home.sff.net/login.asp', [ username => 'jonathanmark', RecordID => 4142]; print "The netloc is" , $req->url->netloc, ". "; $ua->credentials($req->url->netloc, "home.sff.net", 'jonathanmark', 'nottherealpassword'); my$content = $ua->request($req)->as_string; print "Content is $content"; #### The netloc is: home.sff.net. Content is HTTP/1.0 401 (Unauthorized) Access Denied Cache-Control: private Date: Fri, 01 Mar 2002 01:46:04 GMT Via: 1.1 Dyn-EH-NetCache (NetCache NetApp/5.1R2) Server: Greyware Web Server WWW-Authenticate: Basic realm="home.sff.net" Content-Length: 24 Content-Type: text/html Client-Date: Fri, 01 Mar 2002 01:48:51 GMT Client-Peer: 208.14.208.55:80 Error: Access is Denied.