package default_web; require LWP; require LWP::Debug; @ISA = qw(LWP::UserAgent); my $netloc; my $realm; my $uname; my $pass; my $web_url; # Create the user agent object $ua = default_web->new; #pretend these are defined $ua->credentials($netloc, $realm, $uname, $pass); # Set up a request. We will use the same request object for all URLs. $request = HTTP::Request->new(POST => 'http://192.168.1.254/Forms/MyAc +countConfirm'); $request->content_type('application/x-www-form-urlencoded'); $request->content('NST_1stWANPortAuthName=user&NST_NewPassword=pwd&NST +_RepeatPassword=pwd'); # Send the request and get a response back from the server $response = $ua->request($request); print $response->as_string;
In reply to libwww and grab redirect by jweden
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |