Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^2: Fetching URL

by Shaveta_Chawla (Acolyte)
on Oct 04, 2011 at 09:53 UTC ( #929489=note: print w/ replies, xml ) Need Help??


in reply to Re: Fetching URL
in thread Fetching URL

I am trying to fetch a url which contains dynamic value, i have used form method, follow_link method but couldn't succeed. The URL which i have fetched is same that the source is generating but when i am opening that URL on browser,it is giving me wrong page information. May be some cookie based issue.. I am unable to understand the cause as the url is same.. can you guide me what can be the issue..


Comment on Re^2: Fetching URL
Re^3: Fetching URL
by Corion (Pope) on Oct 04, 2011 at 10:04 UTC

    You will need to send exactly the same information that your browser sends. Find out what the browser sends, for example using the Mozilla Live Headers extension or using Wireshark, and then replicate that data from your script.

      Actually the Content length, content header and cookies all the values changes with every request.. I am not able to generate the same header information. Can you guide me on this.

        Extract the cookies from the previous request, and generate the content header and content length headers. Also see WWW::Mechanize, which has solved these problems.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2014-09-16 01:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (155 votes), past polls