Template:ExtensionHook

{{Documentation|content=

Usage notes

 * name
 * The name of the hook. This is usually the same name as the sub-page.


 * version
 * The version of MediaWiki this hook was first introduced in.


 * rev
 * SVN revision in which this hook was first introduced. If this parameter is given, it will link to the appropriate CodeReview page (e.g. r115794).


 * gerrit
 * Gerrit change number in which this hook was first introduced. If this parameter is given, it will link to the appropriate Gerrit changeset page (e.g., 1>gerrit:5|Gerrit change 5)


 * removed
 * If the hook has been removed, the version of MediaWiki that it was removed in.


 * deprecated
 * If the hook has been deprecated (but not removed), the version of MediaWiki that it was deprecated in.


 * summary
 * A short description of the hook's purpose.
 * More detailed descriptions are desirable, and should be added to the main page content.
 * If you update the short description, please also update the two tables on .


 * args
 * The arguments, as used at the top of the function.


 * extension
 * Extension name where hook is called; for when the source is not in the MediaWiki core code repository.


 * source
 * Location (file name) which calls this hook in the code. Further locations can be added via source2...source10.


 * sourcefunction
 * Name of the function which calls this hook. Another can be added via sourcefunction2.


 * sourceclass
 * Name of the class which calls this hook.


 * newvarname
 * Used by Removed or Deprecated when removed or deprecated</> is set.


 * newvarlink
 * Used by <tvar|1>Removed</> or <tvar|2>Deprecated</> when <tvar|3>removed</> or <tvar|4>deprecated</> is set.


 * templatemode
 * Set to <tvar|nocats>nocats</> if hook documentation should not appear in standard MediaWiki Categories.
 * By default, using this template places the documentation page into categories:
 * MediaWiki hooks
 * Hooks added in MediaWiki...
 * There are times when it is undesirable to automatically categorize the hook documentation. Examples would include when documenting a hook in an extension, or when documenting the template itself.


 * nocatdesc
 * If a hook is removed completely from MediaWiki version by setting <tvar|1> </>, it will not show up the category description.

Template data
{	"params": { "templatemode": { "label": { "en": "Template mode", "fr": "Mode du modèle" },			"type": "string", "description": { "fr": "Mettre nocats si la documentation de l'accroche ne doit pas apparaître dans les catégories standards de MediaWiki. On peut ne pas vouloir catégoriser la documentation de l'accroche : documenter une accroche dans une extension, ou documenter le modèle lui-même. " },			"default": { "fr": "La page de documentation est placée dans les catégories des accroches Mediawiki, des accroches ajoutées à Mediawiki..." }		},		"name": { "label": { "en": "Name", "fr": "Nom" },			"description": { "en": "The name of the hook. This is usually the same name as the sub-page.", "fr": "nom de l'accroche (habituellement c'est celui de la sous-page)." },			"type": "string", "required": true },		"removed": { "label": { "en": "Version removed", "fr": "Supprimé" },			"description": { "en": "If the hook has been removed, the version of MediaWiki that it was removed in.", "fr": "version de MediaWiki dans laquelle l'accroche a été supprimée (si c'est le cas)" },			"type": "string" },		"newvarname": { "label": { "en": "Replacement name", "fr": "Nouveau nom" },			"description": { "en": "If the hook is either deprecated or removed, name the feature that replaces this hook, if there is any replacement.", "fr": "nom utilisé par ou  lorsque removed ou deprecated sont positionnés." },			"type": "string" },		"newvarlink": { "label": { "en": "Replacement link", "fr": "nouveau lien" },			"description": { "en": "If the hook is either deprecated or removed, link to the feature that replaces this hook, if there is any replacement.", "fr": "lien utilisé par ou  lorsque removed ou deprecated sont positionnés." },			"type": "wiki-page-name" },		"deprecated": { "label": { "en": "Version deprecated", "fr": "Obsolète" },			"description": { "en": "If the hook has been deprecated, the version of MediaWiki that it was deprecated in.", "fr": "version de MediaWiki où l'accroche est obsolète (si l'accroche est déclarée obsolète et n'a pas été supprimée)" },			"type": "string" },		"version": { "label": { "en": "Version introduced", "fr": "Version" },			"description": { "en": "The version of MediaWiki this hook was first introduced in.", "fr": "version de MediaWiki où l'accroche a été introduite." },			"type": "string", "suggested": true },		"rev": { "label": { "en": "SVN revision introduced", "fr": "Révision" },			"description": { "en": "SVN revision in which this hook was first introduced. If this parameter is given, it will link to the appropriate CodeReview page.", "fr": "Numéro SVN de révision avec laquelle cette accroche a été introduite la première fois. Quand ce paramètre est fourni, il est lié à la page correspondante de la revue de code." },			"type": "string", "example": { "fr": "rev=r115794" }		},		"gerrit": { "label": { "en": "Gerrit changeset introduced", "fr": "Gerrit" },			"description": { "en": "Gerrit change number in which this hook was first introduced. If this parameter is given, it will link to the appropriate Gerrit changeset page.", "fr": "numéro de modification Gerrit par lequel cette accroche a été introduite la première fois. Si ce paramètre est fourni, il sera lié à la page de ll'ensemble de corrections correspondant de Gerrit. " },			"type": "number", "suggested": true, "example": { "fr": "gerrit=5" }		},		"summary": { "label": { "en": "Summary", "fr": "Résumé" },			"description": { "en": "A short description of the hook's purpose. More detailed descriptions are desirable, and should be added to the main page content.", "fr": "Courte présentation de l'accroche. La description complete se trouve dans le contenu de la page principale. Si vous mettez a jour la description courte, mettez à jour également les deux tables de Manual:Hooks." },			"type": "string", "suggested": true },		"args": { "label": { "en": "Arguments", "fr": "Arguments" },			"description": { "en": "The arguments that are defined by the hook signature.", "fr": "tels qu'il sont utilisés à l'entrée de la fonction" },			"required": true, "type": "string" },		"extension": { "label": { "en": "Extension name", "fr": "Extension" },			"description": { "en": "Extension name where the hook is called; for when the source is not in the MediaWiki core code repository.", "fr": "nom de l'extension où l'accroche est appelée; dans les cas où le source n'est pas dans le dépôt de code du noyau MediaWiki." },			"type": "wiki-page-name", "required": true },		"source": { "label": { "en": "Source 1", "fr": "Source" },			"description": { "en": "Location (file name) which calls this hook in the code.", "fr": "endroit (nom du fichier) qui appelle cette accroche dans le code. D'autres endroits peuvent être ajoutés avec source2 ... source10" },			"type": "string", "suggested": true },		"source2": { "label": "Source 2", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source3": { "label": "Source 3", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source4": { "label": "Source 4", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source5": { "label": "Source 5", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source6": { "label": "Source 6", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source7": { "label": "Source 7", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source8": { "label": "Source 8", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source9": { "label": "Source 9", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"source10": { "label": "Source 10", "description": "Location (file name) which calls this hook in the code, if another source exists", "type": "string" },		"sourcefunction": { "label": "Source function", "description": "Name of the function which calls this hook", "type": "string", "suggested": true },		"sourceclass": { "label": "Source class", "description": "The fully qualified class name (FQCN) which calls this hook.", "suggested": true, "type": "string" },		"sourcefunction2": { "label": "Source function 2", "description": "Name of the function which calls this hook, if another functions call this hook", "type": "string" },		"nocatdesc": { "label": "No category description", "description": "Allows to hide the category hook description if the hook was removed completely from MediaWiki version.", "type": "string" }	},	"description": { "en": "A card which describes the information of a hook registered by an extension.", "fr": "Une fiche décrivant les informations d'une accroche enregistrée par une extension." },	"paramOrder": [ "templatemode", "name", "rev", "gerrit", "version", "deprecated", "removed", "newvarname", "newvarlink", "summary", "args", "extension", "source", "source2", "source3", "source4", "source5", "source6", "source7", "source8", "source9", "source10", "sourceclass", "sourcefunction", "sourcefunction2", "nocatdesc" ],	"format": "block" }