Skip to content

Instantly share code, notes, and snippets.

#!/usr/local/bin/perl --
use strict;
use warnings;
use Web::Scraper;
use HTML::TreeBuilder::LibXML;
sub get_data {
my $endpoint = URI->new(qq!http://ladio.net/list/!);
#!/usr/local/bin/perl --
use strict;
use warnings;
use JSON::Syck;
use LWP::UserAgent;
my $agent = LWP::UserAgent->new;
my $a = shift or die;
#!/usr/local/bin/perl
use strict;
use warnings;
use URI;
use IO::Socket;
use MIME::Base64;
use JSON::Syck;
# $username, $password, $status は適宜変更しよう。
# $status は投稿前に urlencode するとかしましょう。
# 超手抜き。
$c = curl_init("http://{$username}:{$password}@twitter.com/statuses/update.xml?status={$status}");
curl_setopt($c, CURLOPT_POST, 1);
curl_exec($c);
curl_close($c);
var Pool = function (name, value) {
var self = arguments.callee;
if ( typeof self.stash == "undefined" ) self.stash = {};
if ( Boolean(name) === false ) return false;
var item = self.stash[name];
if ( typeof value == "undefined" ) delete self.stash[name];
if (value) self.stash[name] = value;
#!/usr/local/bin/perl --
use strict;
use warnings;
use URI;
use Web::Scraper;
use YAML;
my $endpoint = 'http://movapic.com/hoge/follower?max=9999';