Test:
Use the methods which can be directly used with $m->
Solution:
use warnings;
use WWW::Mechanize;
my $m = WWW::Mechanize->new();
$m->get("http://www.rediff.com");
print "URL is- ".$m->uri()."\n";
print "Status code is- ".$m->status()."\n";
print "Content type is- ".$m->content_type()."\n";
print "Base URI is- ".$m->base()."\n";
print "is content HTML- ".$m->is_html()."\n";
print "title is- ".$m->title()."\n";

No comments:
Post a Comment