Rechercher une page de manuel
Jifty::Plugin::Comment::Notification::CommentPublished.3pm
Langue: en
Version: 2008-04-08 (ubuntu - 07/07/09)
Section: 3 (Bibliothèques de fonctions)
NAME
Jifty::Plugin::Comment::Notification::CommentPublished - new comments madeSYNOPSIS
To activate this notification, you must override the notification in your application.use strict; use warnings; package MyApp::Notification::CommentPublished; use base qw/ Jifty::Plugin::Comment::Notification::CommentPublished /; sub setup { my $self = shift; # Send to the author of the post $self->to_list($self->parent->author); $self->SUPER::setup(@_); } sub url { my $self = shift; return Jifty->config->framework('Web')->{'BaseURL'} . $self->parent->permalink . '#comment-'.$self->comment->id; } 1;
DESCRIPTION
This notification (when properly configured) is sent out to any who need to know when a comment has been published.METHODS
setup
This method sets up the notification. This method should be overridden to setup ``to_list'' in Jifty::Notification to select who will receive this message. See the ``SYNOPSIS''.comment
This will contain the Jifty::Plugin::Comment::Model::Comment that has been published.parent
This will contain the object that the comment has been attached to.url
This returns the URL that the message will link to. This should be overridden to provide application-specific URLs. The default implementation returns the BaseURL setting for the application.SEE ALSO
Jifty::Notification, Jifty::Plugin::Comment::Notification::CommentNeedsModerationAUTHOR
Andrew Sterling Hanenkamp, "<hanenkamp@cpan.org>"COPYRIGHT AND LICENSE
Copyright 2008 Boomer Consulting, Inc. All Rights Reserved.This program is free software and may be modified and distributed under the same terms as Perl itself.
Contenus ©2006-2024 Benjamin Poulain
Design ©2006-2024 Maxime Vantorre