Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: html parsing

by shmem (Chancellor)
on Mar 22, 2017 at 15:11 UTC ( [id://1185464]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $req = HTTP::Request->new(GET => 'https://www.google.com');
    $req->content_type('application/json');
    my $res = $ua->request($req);
    
  2. or download this
    use LWP;
    my $ua = LWP::UserAgent->new;
    my $req = HTTP::Request->new(GET => 'https://www.google.com');
    $req->content_type('application/json');
    my $res = $ua->request($req);
    
  3. or download this
    my $title;
    $res->content =~ m|<title>(.+?)</title>|i and $title = $1;
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (7)
As of 2024-04-23 13:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found