shivanisai has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's minimum standard of quality and will not be displayed.
  • Comment on POST method in Scrappy module doesn't return Http::Response object

Replies are listed 'Best First'.
Re: POST method in Scrappy module doesn't return Http::Response object
by ww (Archbishop) on May 25, 2011 at 12:17 UTC

    What is this? Your fourth question about using Scrappy?

    I need to change the tracks on my bulldozer. How can i do this using Scrappy module? And when I get the tracks changed, I'm going to use the 'dozer to sew up a new napkin. Would someone please also give me the code for doing that?

    Use a tool that works for the work you're trying to do!

      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.

        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"
Re: POST method in Scrappy module doesn't return Http::Response object
by MidLifeXis (Monsignor) on May 25, 2011 at 12:14 UTC

    Some actual details on how you tried would probably help. See How (not) to ask a question, then please fill in some details, like the actual code you tried.

    --MidLifeXis