Created
February 10, 2016 02:08
-
-
Save osyoyu/60e904c1847976c3d4c5 to your computer and use it in GitHub Desktop.
saikoh.tk を Perl で叩くやつ
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use strict; | |
use warnings; | |
require LWP; | |
require HTTP::Request; | |
package SaikohTk; | |
sub new { | |
my $class = shift; | |
return bless { | |
ua => LWP::UserAgent->new | |
}, $class; | |
} | |
sub saikoh { | |
my $self = shift; | |
my $request = HTTP::Request->new(GET => 'http://saikoh.tk/click/saikou'); | |
$self->{ua}->request($request); | |
1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use strict; | |
use warnings; | |
require "SaikohTk.pm"; | |
my $saikoh = SaikohTk->new; | |
$saikoh->saikoh(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment