Extension:Comments/Hooks/Comment::add

From Linux Web Expert

Revision as of 18:29, 19 March 2020 by imported>Shirayuki (update)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Comment::add
Available from version ???

Define function:
public static function onComment_add( $comment, $commentId, $comment->page->id ) { ... }
Attach hook:
$wgHooks['Comment::add'][] = 'MyExtensionHooks::onComment_add';
Called from:File(s): Comments / Comment.php
Function(s): add

For more information about attaching hooks, see Manual:Hooks .
For examples of other extensions using this hook, see Category:Comment::add extensions.

Details

  • $comment
  • $commentId
  • $comment->page->id