Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Checking contents of fetched URL.

by holli (Monsignor)
on Jan 29, 2010 at 22:54 UTC ( #820419=note: print w/ replies, xml ) Need Help??


in reply to Checking contents of fetched URL.

The presence of ->content in your output should have given you a hint. The term $res->content does not get interpolated, only $res does.

You want: print "\nResponse = ", $res->content, " \n"; just as you did in the two lines above.



holli

You can lead your users to water, but alas, you cannot drown them.


Comment on Re: Checking contents of fetched URL.
Select or Download Code
Re^2: Checking contents of fetched URL.
by ajay.awachar (Acolyte) on Jan 29, 2010 at 23:43 UTC

    I got your point on interpolation problem with $res->content. But even after replacing it with

     print "\nResponse = ", $res->content, " \n";

    I am still not getting the exact contents. I'm not getting any output for $res->content. I even tried  print "Response =  ".$res->as_string(); but it gives me some errors regarding unavailability of HTML/HeadParser.pm. Any idea on this.

    Ajay

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2014-07-26 11:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (175 votes), past polls