Manual:Hooks/GalleryGetModes/de

This page is a translated version of the page Manual:Hooks/GalleryGetModes and the translation is 20% complete.
GalleryGetModes
Erhältlich ab Version 1.22.0 (Gerrit change 67885)
Allows extensions to add classes that can render different modes of a gallery.
Funktion definieren:
public static function onGalleryGetModes( array &$modeArray ) { ... }
Haken anbringen: In extension.json:
{
	"Hooks": {
		"GalleryGetModes": "MyExtensionHooks::onGalleryGetModes"
	}
}
Angerufen von: Datei(en): gallery/ImageGalleryBase.php
Interface: GalleryGetModesHook.php

For more information about attaching hooks, see Handbuch:Hooks .
For examples of extensions using this hook, see Category:GalleryGetModes extensions/de.

Details

Allows an extension to add custom classes to render a gallery with. Add the mode name and the class to the associative array.

  • &$modeArray: An associative array mapping mode names to classes that implement that mode. It is expected all registered classes are a subclass of ImageGalleryBase.