Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: Screen scraper

by shonorio (Hermit)
on Jan 10, 2007 at 10:11 UTC ( [id://593869]=note: print w/replies, xml ) Need Help??


in reply to Screen scraper

MKevin,

You can use a HTTP::Record to help you to create a Mechanize script, as a like Web Testing with HTTP::Recorder article.

The code bellow do what you want, and don't forget to print to a file, that I didn't.

use WWW::Mechanize; my $agent = WWW::Mechanize->new(); $agent->get('http://vortex.plymouth.edu/uacalplt-u.html'); $agent->form_number(1); $agent->field('pt', 'parcel'); $agent->field('mm', '08'); $agent->field('dd', '24'); $agent->field('pl', 'none'); $agent->field('size', '640x480'); $agent->field('yy', '05'); $agent->field('id', 'KMIA'); $agent->field('hh', '00'); $agent->click(); print $agent->{content};

Solli Moreira Honorio
Sao Paulo - Brazil

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://593869]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2024-03-28 21:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found