Extension hook registry
From MediaWiki.org
This page is for registering hooks created by your extension. If you would like to document hooks used by your extension, please use the hook1, hook2, etc parameters on the Extension template embedded in your extension article. |
The Hooks mechanism in MediaWiki is a powerful tool for extension authors to modify the behavior of MediaWiki while minimizing, if not eliminating, the need to hack the codebase. A logical extension of this idea is to place hooks in extensions themselves, in order to allow other developers to extend the extensions. This page provides a listing and documentation for hooks provided by extension authors. To document your hook:
- create a page named after the hook under your extension, e.g.
Extension:MyExtension/MyHook. Note: this naming convention allows defaults and category links in Template:Extension and Template:SeeCustomHook to work properly - place the Template:Extension in your page and fill in the parameter values
- add a row for your hook in the table below
[edit] Extension Hooks by Parent Extension
| Parent Extension | Version | Hook | Description |
|---|---|---|---|
| CategoryHook | 0.2 | CategoryHook | Adds a hook allowing articles to be added to additional categories based on wikitext content. |
| LDAP Authentication | 1.1c+ | SetUsernameAttributeFromLDAP | Allows hook function to set the LDAP username from various attributes returned by a query. |
| PagesOnDemand | 0.1 | PagesOnDemand | Hook for modules that create new pages from templates when links to nonexistent pages are followed |
| DatabaseFetchObject | 0.1 | DatabaseFetchObject | Hook for checking permissions in any context where database page contents are retrieved. |
| ImagePageEx | ImagePageEx | Hooks for trapping delete related changes in NS_IMAGE | |
| Backup | Backup | Hook event called when a page change is effected |
Extensions: Category — All — Requests — Tag extensions — Extension Matrix — Extensions FAQ — Extension hook registry — {{Extension}}

