POE::Component::IRC::Plugin::Validator::CSS is a non-blocking CSS validator for IRC bots.
SYNOPSIS
use strict;
use warnings;
use POE qw(Component::IRC Component::IRC::Plugin::Validator::CSS);
my $irc = POE::Component::IRC->spawn(
nick => 'CSSValidator',
server => 'irc.freenode.net',
port => 6667,
ircname => 'CSS Validator Bot',
) or die "Oh noes :( $!";
POE::Session->create(
package_states => [
main => [ qw(_start irc_001) ],
],
);
$poe_kernel->run;
sub _start {
$irc->yield( register => 'all' );
# register our plugin
$irc->plugin_add(
'CSSValidator' =>
POE::Component::IRC::Plugin::Validator::CSS->new
);
$irc->yield( connect => {} );
}
sub irc_001 {
my ( $kernel, $sender ) = @_[ KERNEL, SENDER ];
$kernel->post( $sender => join => '#zofbot' );
}
[18:05:00] CSSValidator, cssval http://zoffix.com
[18:05:01] (zoffix.com) Valid ( http://jigsaw.w3.org/css-validator/validator?uri=http://zoffix.com )
Product's homepage
Requirements:
· Perl