Help:Extension:Translate/Group configuration/MediaWiki/nl

From mediawiki.org
This page is a translated version of the page Help:Extension:Translate/Group configuration/MediaWiki and the translation is 100% complete.

Dit is een documentatie over hoe u MediaWiki-extensiegroepen kunt instellen met behulp van het eenvoudige tekstconfiguratiebestand. Het is nuttig als u honderden extensies heeft.

Deze configuratie gaat naar de LocalSettings.php in de map van MediaWiki.

require "$IP/extensions/Translate/Translate.php";

$wgHooks['TranslatePostInitGroups'][] = function ( &$list, &$deps, &$autoload ) {
	$def = "/path/to/mediawiki-extensions.txt";
	$path = '%GROUPROOT%/extensions/';

	$parser = new PremadeMediawikiExtensionGroups( $def, $path );
	$parser->register( $list, $deps, $autoload );

	return true;
}

Configuratie-bestand

Hier is een voorbeeld van een configuratie-bestand:

Simple Extension

Complex Extension
desc = Some text here.
ignored = sidebar, robots.txt
optional = grouppage-recursive-export
prefix = wmf- | sidebar, grouppage-Staff, group-Staff, group-Staff-member
aliasfile = ComplexExtension.alias.php
magicfile = ComplexExtension.magic.php

De algemene syntaxis is: Naam van de extensie gevolgd door een lijst met keys en values en Ă©Ă©n lege regel voor de volgende extensie.

ExtensionName - Naam van de extensie met verwijderde spaties.

De beschikbare keys zijn:

aliasfile
Locatie van het bestand met speciale pagina's, alias vertalingen voor deze extensie, in relatie tot $wgTranslateExtensionDirectory
desc
Beschrijving van de extensie die aan vertalers wordt getoond
descmsg
Een pagina in de MediaWiki-namespace met de beschrijving van de extensie die aan vertalers wordt getoond
file
Locatie van het bestand met berichten voor deze extensie. De standaardwaarde is afhankelijk van het formaat:
  • php: ExtensionName/ExtensionName.i18n.php
  • json: ExtensionName/i18n/%CODE%.json
format
Het bestandsformaat dat wordt gebruikt door de extensie. De ondersteunde waarden zijn php en json. Standaardwaarde: format = php
id
Berichtengroep-id. De standaardwaarde is ExtensionName in klein letters met het voorvoegsel ext-. For example, "Complex Extension" has default id of "ext-complexextension"
ignored
List of comma separated message keys which will not be shown for the translators. This key can be present in multiple times to split the list into multiple lines.
magicfile
Location of file containing magic word translations for this extension relative to $wgTranslateExtensionDirectory
optional
List of comma separated message keys which will be shown to translators only if they select to see optional messages. Optional messages are not counted as untranslated messages, but translated optional messages are counted as translated. This key can be present multiple times.
prefix
To handle conflicting message keys, you can prefix given messages. The syntax is first to have the prefix separated by pipe from comma separated list of message keys. This key can be present multiple times.
var
Name of the php variable holding the messages. Defaults to $messages.