# Blosxom Plugin: digg_me
# Author: Dean Wilson
# Version: 0.1 (2006028)
# Plugin Homepage: # http://www.unixdaemon.net/blosxom_plugins.html#digg_me
# License: GPL
# Documentation: Please see the end of this file.
package digg_me;
use strict;
sub start {
1;
}
sub story {
my ($pkg, $path, $filename, $story_ref, $title_ref, $body_ref) = @_;
# change this to match your permalink format.
my $post_url
= "$blosxom::url$blosxom::path/$blosxom::fn.$blosxom::flavour";
my $title = $$title_ref;
my $link_desc = 'Digg Me!';
my $del_base_url = q{http://www.digg.com/submit?};
my $del_full_url = "url=$post_url&title=$title&phase=3";
my $del_post_esc = $del_full_url;
$$body_ref .= qq{
};
$$body_ref .= qq{$link_desc};
1;
}
1;
__END__
=head1 NAME
Blosxom Plugin: digg_me
=head1 SYNOPSIS
This extension adds a 'Digg Me!' link to the bottom of every blog post
and RSS item. It was inspired by an XML.com article on Immediate
Action Feeds
http://www.xml.com/lpt/a/2005/12/14/putting-rss-to-work-immediate-action-feeds.html
Notes:
If you plan to use this on your own blosxom powered site you'll probably
need to change $post_url to suit your own permalink style.
This plugin currently creates a CGI object way too often. If you build a
static version of your site this won't be a problem. If your
site is completely dynamic it's worth watching.
=head1 VERSION
0.1
=head1 AUTHOR
Dean Wilson
=head1 LICENSE
GPL
=cut