Emulate browser request

Brian Raven - Equity Options (brianr@mrpotatohead.liffe.com)
Wed, 14 Jul 1999 10:28:21 +0100 (BST)


White, Solomon writes:
 > I'm a newbie to libwww.  I want to build a script to send a query to a
 > search engine, get all the results (send more requests to get all the
 > pages), then parse/sort/process the results.  I was able to connect to the
 > search engine, but it responds to please access through the main page of the
 > search engine.  I assume this means I'm not passing some of the right HTTP
 > headers that the script on the other side is looking for.  Is there a way to
 > capture exactly what my browser is sending when I submit the form on the
 > main page and then duplicate that in my script?

Have a look at WWW::Search in CPAN. It sounds like it does a lot of
what you want.

-- 
Brian Raven

s = (char*)(long)retval;                /* ouch */
             -- Larry Wall in doio.c from the perl source code