Skip to content

Instantly share code, notes, and snippets.

@sodonnell
Created July 11, 2018 22:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sodonnell/a9b7d0bfa4527924b2d0a3b846379e9d to your computer and use it in GitHub Desktop.
Save sodonnell/a9b7d0bfa4527924b2d0a3b846379e9d to your computer and use it in GitHub Desktop.
print pQuery->get($url)->title;
#!/usr/bin/perl
use strict;
use warnings;
# install pQuery:
# sudo cpanm pQuery;
use pQuery;
my $url = "https://github.com/sodonnell/plowbot/";
print "URL: ". $url ."\nTitle: ";
print pQuery->get($url)->title ."\n";
# much easier than using LWP+regexp.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment