http://www.perlmonks.org?node_id=482548


in reply to Use LWP::UserAgent to go to a password protected ASP page

PLease check if this can help you
=======================================
use strict;<br> use WWW::Mechanize;<br> my $username = "USER"; # Login<br> my $password = "PASSWORD"; # Password<br> my $url = "http://www.myurl.com"; # Your URL Name<br> my $mech = WWW::Mechanize->new();<br> $mech->get($url);<br> ## Browse the HTML source of the ASP page to get these parameters <br> $mech->form("form_Name"); # The Login Form Name<br> $mech->field("txt_id", $username); # Username Texbox name<br> $mech->field("txt_pwd", $password); # Password Textbox name<br> $mech->click("cmd_ok"); # Button name<br> my $current_site = $mech->{uri}; #The $current_site would give you the address of next page...
- SanPerl