I tried to login using this script but i am getting error
use WWW::Mechanize::Firefox;
my $mech = WWW::Mechanize::Firefox->new(
activate => 1,
autoclose => 0,);
my $url = "https://accounts.google.com/Login";
$mech->get($url);
$result = $mech->submit_form(
form_id => 'gaia_loginform',
fields =>
{
Email => 'xxxx@gmail.com', # name of the input field and value
Passwd => 'xxx',
}
,button => 'signIn' #name of the submit button
);
print $result->content();
On running the script I get the error No form found to submit. at gmail.pl line 12. Can any one please look at the issue.
Thanks in advance |