Help for this page
use LWP::UserAgent; $ua = new LWP::UserAgent; $req = new HTTP::Request GET => 'http://www.sn.no/secret/'; $req->authorization_basic('aas', 'mypassword'); print $ua->request($req)->as_string; # the above code returns the html code for the form
use LWP::UserAgent; $ua = new LWP::UserAgent; $ua->credentials('user', 'password'); ... $req->authorization_basic('aas', 'mypassword'); print $req->status_line, "\n"; # the above returns 401 Access Denied