Notify the content author about new comments

Required modules: Comment Module

array (
  'cfg_1' =>
  array (
    '#type' => 'configuration',
    '#altered' => false,
    '#event' => 'comment_insert',
    '#label' => 'Notify content author about new comments',
    '#active' => 1,
    '#module' => 'workflow-ng',
    0 =>
    array (
      '#type' => 'action',
      '#name' => 'workflow_ng_action_mail_to_user',
      '#settings' =>
      array (
        'message' => 'Hello [node_author:user]!

A new comment has been created by [comment:comment-author-name] at your [node:type-name] [node:title].
[node:site-url]/node/[node:nid]#comment-[comment:comment-cid]

Comment title: [comment:comment-title]
Comment body:
[comment:comment-body]

---[comment:site-name]',
        'subject' => 'A new comment has been created!',
        'from' => 'yourmail@example.com',
        'from_args' =>
        array (
        ),
        'message_args' =>
        array (
          0 => 'comment',
          1 => 'node',
          2 => 'node_author',
        ),
        'subject_args' =>
        array (
        ),
      ),
      '#label' => 'Notify the content author',
      '#argument map' =>
      array (
        'node_author' => 'user',
      ),
    ),
    '#name' => 'cfg_1',
  ),
)

Possible to notify only if comment = Approved/published?

pierrelord - July 2, 2008 - 15:32

This is great - Thank you - Would it be possible to notify only if comment = Approved/published? - The context is a multi-blogger site whose comment-moderation is done centrally by one person. Ideally We'd like to notify bloggers only when a comment on their posts is actually approved.. Is this possible? How should I go about doing this? Thanks in advance. Pierre

 
 

Drupal is a registered trademark of Dries Buytaert.