Index: trunk/phase3/docs/hooks.txt |
— | — | @@ -252,6 +252,10 @@ |
253 | 253 | 'AddNewAccount': after a user account is created |
254 | 254 | $user: the User object that was created. (Parameter added in 1.7) |
255 | 255 | |
| 256 | +'AjaxAddScript': Called in output page just before the initialisation |
| 257 | +of the javascript ajax engine. The hook is only called when ajax |
| 258 | +is enabled ( $wgUseAjax = true; ). |
| 259 | + |
256 | 260 | 'AlternateEdit': before checking if an user can edit a page and |
257 | 261 | before showing the edit form ( EditPage::edit() ). This is triggered |
258 | 262 | on &action=edit. |
— | — | @@ -356,6 +360,9 @@ |
357 | 361 | &$nt: the image title |
358 | 362 | &$time: image timestamp |
359 | 363 | |
| 364 | +'BeforePageDisplay': Prior to outputting a page |
| 365 | +$out: OutputPage object |
| 366 | + |
360 | 367 | 'BeforeParserFetchTemplateAndtitle': before a template is fetched by Parser |
361 | 368 | &$parser: Parser object |
362 | 369 | &$title: title of the template |
— | — | @@ -384,6 +391,9 @@ |
385 | 392 | $isbn: ISBN to show information for |
386 | 393 | $output: OutputPage object in use |
387 | 394 | |
| 395 | +'CategoryPageView': before viewing a categorypage in CategoryPage::view |
| 396 | +$catpage: CategoryPage instance |
| 397 | + |
388 | 398 | 'ContributionsToolLinks': Change tool links above Special:Contributions |
389 | 399 | $id: User identifier |
390 | 400 | $title: User page title |
— | — | @@ -603,6 +613,11 @@ |
604 | 614 | $title : Page title |
605 | 615 | $text : Current text being indexed |
606 | 616 | |
| 617 | +'ShowRawCssJs': Customise the output of raw CSS and JavaScript in page views |
| 618 | +$text: Text being shown |
| 619 | +$title: Title of the custom script/stylesheet page |
| 620 | +$output: Current OutputPage object |
| 621 | + |
607 | 622 | 'SiteNoticeBefore': Before the sitenotice/anonnotice is composed |
608 | 623 | &$siteNotice: HTML returned as the sitenotice |
609 | 624 | Return true to allow the normal method of notice selection/rendering to work, |
— | — | @@ -617,6 +632,11 @@ |
618 | 633 | &$text: bottomScripts Text |
619 | 634 | Append to $text to add additional text/scripts after the stock bottom scripts. |
620 | 635 | |
| 636 | +'SkinTemplateContentActions': Alter the "content action" links in SkinTemplates |
| 637 | +&$content_actions: Content actions |
| 638 | +[See http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/examples/Content_action.php |
| 639 | +for an example] |
| 640 | + |
621 | 641 | 'SkinTemplateOutputPageBeforeExec': Before SkinTemplate::outputPage() starts page output |
622 | 642 | &$sktemplate: SkinTemplate object |
623 | 643 | &$tpl: Template engine object |
— | — | @@ -644,6 +664,10 @@ |
645 | 665 | $user: user that was watching |
646 | 666 | $article: article object removed |
647 | 667 | |
| 668 | +'UnwatchArticleComplete': after a watch is removed from an article |
| 669 | +$user: user that watched |
| 670 | +$article: article object that was watched |
| 671 | + |
648 | 672 | 'UploadForm:initial': before the upload form is generated |
649 | 673 | $form: UploadForm object |
650 | 674 | You might set the member-variables $uploadFormTextTop and |
— | — | @@ -690,18 +714,6 @@ |
691 | 715 | $add : Array of strings corresponding to groups added |
692 | 716 | $remove: Array of strings corresponding to groups removed |
693 | 717 | |
694 | | -'WatchArticle': before a watch is added to an article |
695 | | -$user: user that will watch |
696 | | -$article: article object to be watched |
697 | | - |
698 | | -'WatchArticleComplete': after a watch is added to an article |
699 | | -$user: user that watched |
700 | | -$article: article object watched |
701 | | - |
702 | | -'UnwatchArticleComplete': after a watch is removed from an article |
703 | | -$user: user that watched |
704 | | -$article: article object that was watched |
705 | | - |
706 | 718 | 'UserGetImplicitGroups': Called in User::getImplicitGroups() |
707 | 719 | &$groups: List of implicit (automatically-assigned) groups |
708 | 720 | |
— | — | @@ -713,29 +725,14 @@ |
714 | 726 | $user: User to get groups for |
715 | 727 | &$groups: Current effective groups |
716 | 728 | |
717 | | -'CategoryPageView': before viewing a categorypage in CategoryPage::view |
718 | | -$catpage: CategoryPage instance |
| 729 | +'WatchArticle': before a watch is added to an article |
| 730 | +$user: user that will watch |
| 731 | +$article: article object to be watched |
719 | 732 | |
720 | | -'SkinTemplateContentActions': after building the $content_action array right |
721 | | - before returning it, see Content_action.php in |
722 | | - the extensions/examples/ directory |
723 | | - ( http://svn.wikimedia.org/viewvc/mediawiki/trunk/extensions/examples/ ) |
724 | | - for a demonstration of how to use this hook. |
725 | | -$content_actions: The array of content actions |
| 733 | +'WatchArticleComplete': after a watch is added to an article |
| 734 | +$user: user that watched |
| 735 | +$article: article object watched |
726 | 736 | |
727 | | -'BeforePageDisplay': Called just before outputting a page (all kinds of, |
728 | | - articles, special, history, preview, diff, edit, ...) |
729 | | - Can be used to set custom CSS/JS |
730 | | -$out: OutputPage object |
731 | 737 | |
732 | | -'ShowRawCssJs': Customise the output of raw CSS and JavaScript in page views |
733 | | -$text: Text being shown |
734 | | -$title: Title of the custom script/stylesheet page |
735 | | -$output: Current OutputPage object |
736 | | - |
737 | | -'AjaxAddScript': Called in output page just before the initialisation |
738 | | -of the javascript ajax engine. The hook is only called when ajax |
739 | | -is enabled ( $wgUseAjax = true; ). |
740 | | - |
741 | 738 | More hooks might be available but undocumented, you can execute |
742 | | -./maintenance/findhooks.php to find hidden one. |
| 739 | +./maintenance/findhooks.php to find hidden one. |
\ No newline at end of file |