MediaWiki REL1_34
|
Hooks for the CategoryTree extension, an AJAX based gadget to display the category structure of a wiki. More...
Static Public Member Functions | |
static | addHeaders (OutputPage $out) |
BeforePageDisplay and BeforePageDisplayMobile hooks. | |
static | articleFromTitle (Title $title, Article &$article=null) |
ArticleFromTitle hook, override category page handling. | |
static | getDataForJs () |
Get exported data for the "ext.categoryTree" ResourceLoader module. | |
static | initialize () |
Adjusts config once MediaWiki is fully initialised TODO: Don't do this, lazy initialize the config. | |
static | onSkinBuildSidebar (Skin $skin, array &$sidebar) |
Hook implementation for injecting a category tree into the sidebar. | |
static | onSpecialTrackingCategoriesGenerateCatLink (SpecialPage $specialPage, Title $catTitle, &$html) |
Hook handler for the SpecialTrackingCategories::generateCatLink hook PhanUndeclaredProperty SpecialPage->categoryTreeCategories. | |
static | onSpecialTrackingCategoriesPreprocess (SpecialPage $specialPage, array $trackingCategories) |
Hook handler for the SpecialTrackingCategories::preprocess hook PhanUndeclaredProperty SpecialPage->categoryTreeCategories. | |
static | outputPageMakeCategoryLinks (OutputPage &$out, array $categories, array &$links) |
OutputPageMakeCategoryLinks hook, override category links. | |
static | parserFunction (Parser $parser,... $params) |
Entry point for the {{#categorytree}} tag parser function. | |
static | parserHook ( $cat, array $argv, Parser $parser=null, $allowMissing=false) |
Entry point for the <categorytree> tag parser hook. | |
static | parserOutput (OutputPage $outputPage, ParserOutput $parserOutput) |
Hook callback that injects messages and things into the <head> tag, if needed in the current page. | |
static | setHooks (Parser $parser) |
static | shouldForceHeaders () |
Hooks for the CategoryTree extension, an AJAX based gadget to display the category structure of a wiki.
Definition at line 29 of file CategoryTreeHooks.php.
|
static |
BeforePageDisplay and BeforePageDisplayMobile hooks.
These hooks are used when $wgCategoryTreeForceHeaders is set. Otherwise similar to CategoryTreeHooks::parserOutput.
OutputPage | $out |
Definition at line 201 of file CategoryTreeHooks.php.
References CategoryTree\setHeaders().
ArticleFromTitle hook, override category page handling.
Definition at line 214 of file CategoryTreeHooks.php.
References $title, and NS_CATEGORY.
|
static |
Get exported data for the "ext.categoryTree" ResourceLoader module.
Definition at line 253 of file CategoryTreeHooks.php.
|
static |
Adjusts config once MediaWiki is fully initialised TODO: Don't do this, lazy initialize the config.
Definition at line 44 of file CategoryTreeHooks.php.
References $wgRequest, and CategoryTree\decodeMode().
|
static |
Hook implementation for injecting a category tree into the sidebar.
Only does anything if $wgCategoryTreeSidebarRoot is set to a category name.
Skin | $skin | |
array | &$sidebar |
Definition at line 124 of file CategoryTreeHooks.php.
References ContextSource\getOutput(), parserHook(), and CategoryTree\setHeaders().
|
static |
Hook handler for the SpecialTrackingCategories::generateCatLink hook PhanUndeclaredProperty SpecialPage->categoryTreeCategories.
SpecialPage | $specialPage | SpecialTrackingCategories object |
Title | $catTitle | Title object of the linked category |
string | &$html | Result html |
Definition at line 302 of file CategoryTreeHooks.php.
References CategoryTree\createCountString(), and SpecialPage\getContext().
|
static |
Hook handler for the SpecialTrackingCategories::preprocess hook PhanUndeclaredProperty SpecialPage->categoryTreeCategories.
SpecialPage | $specialPage | SpecialTrackingCategories object |
array | $trackingCategories | [ 'msg' => Title, 'cats' => Title[] ] |
Definition at line 270 of file CategoryTreeHooks.php.
References $dbr, $res, DB_REPLICA, and wfGetDB().
|
static |
OutputPageMakeCategoryLinks hook, override category links.
OutputPage | &$out | |
array | $categories | |
array | &$links |
Definition at line 227 of file CategoryTreeHooks.php.
References $type, parserHook(), and CategoryTree\setHeaders().
|
static |
Entry point for the {{#categorytree}} tag parser function.
This is a wrapper around CategoryTreeHooks::parserHook
Parser | $parser | |
string | ...$params |
Definition at line 90 of file CategoryTreeHooks.php.
References parserHook(), and true.
|
static |
Entry point for the <categorytree> tag parser hook.
This loads CategoryTreeFunctions.php and calls CategoryTree::getTag() PhanUndeclaredProperty ParserOutput->mCategoryTreeTag
string | $cat | |
array | $argv | |
Parser | null | $parser | |
bool | $allowMissing |
Definition at line 148 of file CategoryTreeHooks.php.
References CategoryTree\capDepth(), and CategoryTree\decodeBoolean().
Referenced by onSkinBuildSidebar(), outputPageMakeCategoryLinks(), and parserFunction().
|
static |
Hook callback that injects messages and things into the <head> tag, if needed in the current page.
Does nothing if $parserOutput->mCategoryTreeTag is not set PhanUndeclaredProperty ParserOutput->mCategoryTreeTag
OutputPage | $outputPage | |
ParserOutput | $parserOutput |
Definition at line 185 of file CategoryTreeHooks.php.
References CategoryTree\setHeaders().
|
static |
Parser | $parser |
Definition at line 74 of file CategoryTreeHooks.php.
References Parser\setFunctionHook(), and Parser\setHook().
|
static |
Definition at line 35 of file CategoryTreeHooks.php.
Referenced by CategoryTreePage\execute(), and CategoryTreeCategoryViewer\getCategoryTree().