Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^2: POST method in Scrappy module doesn't return Http::Response object

by wfsp (Abbot)
on May 25, 2011 at 15:02 UTC ( [id://906665]=note: print w/replies, xml ) Need Help??


in reply to Re: POST method in Scrappy module doesn't return Http::Response object
in thread POST method in Scrappy module doesn't return Http::Response object

My dad drove a bulldozer and he always sang the praises of the Scrappy module when he had to change the tracks. I think in those days the dependancy chain included sledge hammers and very long crow bars. Sadly, the code was on the back of a packet of Woodbines and I think he must have used it to light the acetylene torch (optional).

Mind you, his napkins were rubbish.

Replies are listed 'Best First'.
Re^3: POST method in Scrappy module doesn't return Http::Response object
by shivanisai (Initiate) on May 26, 2011 at 05:35 UTC
    This is the code i have tried.
    use strict; use Scrappy; my $sess = 'sam.session'; my $scraper =Scrappy->new; -f $sess ? $scraper->session->load($sess) : $scraper->session->write($ +sess); my $mainurl="https://secure.samford.edu/php-bin/search/index.php"; my $search_url="https://secure.samford.edu/php-bin/search/dir_susearch +.php"; $scraper->get($mainurl); my $scraper1 =Scrappy->new; -f $sess ? $scraper1->session->load($sess) : $scraper1->session->write +($sess); $scraper1->post("$search_url",{ 'searchChar'=>"john", 'searchBy'=>"ball", 'roleRadioGp'=>"fall", 'submit'=>"submit" }); foreach my $key(keys %$scraper1) { print "\n$key :"; print "$scraper1->{$key}\n"; } $scraper1->logger->write('log.yml');
    In log.yml file always the error will be -- error: - eventlog: "2011-05-26 05:24:29 error error POSTing data to https://secure.samford.edu/php-bin/search/dir_susearch.php"

Log In?
Username:
Password:

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

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

    No recent polls found