Friends
I have an simple "Asante Cable/DSL Router" which gets its IP address from my ISP. I wanted to write a short script that uses WWW::Mechanize to login and scrape out what my IP address is. So here's the scripts I wrote (Removing my actual password of course) ...
... when I run this I get ...#!/usr/bin/perl -w use strict; use WWW::Mechanize; use Data::Dumper; my $mech = WWW::Mechanize->new(); my $url = "http://192.168.123.254/begin.htm"; print "Getting $url ...\n"; $mech->get( $url ); print "Got!\n"; my $fields = { 'URL' => 'XXXXXXXX' }; #print Dumper ( $mech ); print "Submitting form ... \n"; my $r = $mech->submit_form( form_name => 'LOGIN', fields => $fields ); if ( $r->is_success ) { print "logged on!\n"; } else { print "Couldn't submit form:$!\n"; }
Anyone out there know why I might be getting this error and want I can do about it?Couldn't submit form:Connection reset by peer
In reply to Get IP address from my Asante Cable/DSL router by Plankton
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |