Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
March 24, 2005, 5:41 pm
rate this thread
Here is the sample scenario :
A cgi request is going to a server say a webserver or a application
server, that server is configured to redirect this request to a
This html page is just a test page just to get this request.
Now I want to retrieve the header information of this sample.html page.
Is there anyway we can script to get header information from
sample.html whenever the server redirects all request to this
Re: how to retrieve the header information from a html page ???
> A cgi request is going to a server say a webserver or a application
> server, that server is configured to redirect this request to a
> "sample.html" page.
Start with LWP. Create a user agent and submit a POST requst to the form.
When a response comes back, it will be a redirect to the sample page.
Examine the response to get the URL of the sample page, then do a second
HEAD request to that URL.
That's the general idea. For details, see the LWP module on CPAN. For higher
level automation - session tracking, form parsing, etc. - have a look at
WWW::Mechanize, also on CPAN.
Cocoa programming in Perl: http://camelbones.sourceforge.net
Hire me! My resume: http://www.dot-app.org