$out: OutputPage instance (object)
$parserOutput: parserOutput instance being added in $out
+'OutputPageMakeCategoryLinks': links are about to be generated for the page's categories.
+ Implementations should return false if they generate the category links, so the default link generation is skipped.
+$out: OutputPage instance (object)
+$categories: associative array, keys are category names, values are category types ("normal" or "hidden")
+$links: array, intended to hold the result. Must be an associative array with category types as keys and arrays of HTML links as values.
+
'PageHistoryBeforeList': When a history page list is about to be constructed.
$article: the article that the history is loading for
}
# Add the remaining categories to the skin
- $sk = $wgUser->getSkin();
- foreach ( $categories as $category => $type ) {
- $title = Title::makeTitleSafe( NS_CATEGORY, $category );
- $text = $wgContLang->convertHtml( $title->getText() );
- $this->mCategoryLinks[$type][] = $sk->makeLinkObj( $title, $text );
+ if ( wfRunHooks( 'OutputPageMakeCategoryLinks', array( &$this, $categories, &$this->mCategoryLinks ) ) ) {
+ $sk = $wgUser->getSkin();
+ foreach ( $categories as $category => $type ) {
+ $title = Title::makeTitleSafe( NS_CATEGORY, $category );
+ $text = $wgContLang->convertHtml( $title->getText() );
+ $this->mCategoryLinks[$type][] = $sk->makeLinkObj( $title, $text );
+ }
}
}