Help:Magic words/hu

A varázsszavak különböző értékeket vagy függvényeket (például idő, lapinformációk vagy oldalnevek) jeleníthetnek meg. Ez a lap csak az alapértelmezett varázsszavakat mutatja be; a műszaki magyarázatot lásd a lapon.

A varázsszavaknak három típusa van:


 * Kapcsolók: két dupla alsóvonás közti nagybetűs szavak (például  )
 * Változók: nagybetűs szavak dupla kapcsos zárójelek között (például  ), így a wikikódban a sablonokhoz hasonlóan jelennek meg.
 * Elemzőfüggvények:   vagy   formában paramétereket lehet nekik megadni, például . Lásd még: és

A változók és elemzőfüggvények a sablonokhoz hasonlóan behelyettesíthetőek. A lapfüggő varázsszavak alapértelmezésben az aktuális lapra vonatkozó információkat jelenítik meg akkor is, ha sablonon vagy rendszerüzeneten keresztül vannak beillesztve.

Kapcsolók
A behavior switch controls the layout or behavior of the page (if supported by the skin) and can often be used to specify desired omissions and inclusions in the content. Notably some of these are not supported by the Minerva skin.

Változók
Variables return information about the current page, wiki, or date. Their syntax is similar to templates. Variables marked as " [expensive] " are tracked by the software, and the number that can be included on a page is limited.

If a template name conflicts with a variable, the variable will be used (so to transclude the template    :PAGENAME you would need to write  ). In some cases, adding parameters will force the parser to invoke a template; for example,  transcludes     :CURRENTDAYNAME, not the variable.

Dátum és idő
Az alábbi változók a UTC szerinti időt jelenítik meg.

Due to MediaWiki and browser caching, these variables frequently show when the page was cached rather than the current time.

The use of those variables cause pages to be cached for a more limited number of seconds. This is configured in MagicWordFactory.

The date and time magic words are formatted in the wiki content language. Since, they depend on the page content language.

{{note|1= {{tlx|CURRENTDATE}} is not a magic word but it might be a template.

The following variables do the same as the preceding ones but using the site's server config or {{mediawiki|Special:MyLanguage/Manual:$wgLocaltimezone|$wgLocaltimezone}}.



For more thorough time formatting, or to output the current year and week with better compliance with ISO-8601, you may want to install {{ll|Extension:ParserFunctions}} to use the {{ll|Help:Extension:ParserFunctions#.23time| # time}} parser function.

{{anchor|Technical metadata}}

Statisztikák
Numbers returned by these variables normally contain separators (commas, dots or spaces, depending on the local language) but can return raw numbers with the ":R" flag (for example,  &rarr;  and   &rarr; ).

Use "|R" for magic words that require a parameter like PAGESINCATEGORY (for example  and , or   and  ). Also applicable to  hereinbefore.

The number magic words are formatted in the wiki content language. Since, it depends on the page content language.

Lapnevek
None of these are affected by changes to the display title using ; the values returned are the original page title.

The  and   magic words only work in namespaces that have subpages enabled. See for information on enabling subpages.

As of 1.15+, these can all take a parameter, allowing specification of the page to be operated on, instead of just the current page:



URL encoded page names
The following are equivalents encoded for use in MediaWiki URLs (i.e. spaces replaced with underscores and some characters HTML escaped using numeric character encoding):



Note that,   and   have distinct implementations. See for details.

Névterek
The following are equivalents encoded for use in MediaWiki URLs (spaces replaced with underscores and some characters percent-encoded):



As of 1.15+, these can take a full-page-name parameter and will return the requested namespace associated with that page, instead of with the current page:

A paraméter nem lehet egy névtér neve:
 * &rarr; 
 * &rarr;  (Pages in main space will return empty)
 * &rarr; 
 * &rarr; 
 * &rarr; 
 * &rarr; 
 * &rarr;   (Empty)

Elemzőfüggvények
Parser functions are very similar to variables but take one or more parameters (technically, any magic word that takes a parameter is a parser function), and the name is sometimes prefixed with a hash to distinguish them from templates.

This page only describes parser functions that are integral to the MediaWiki software. Other parser functions may be added by MediaWiki extensions such as the. For those see.

Névterek
returns the current localized name for the namespace with that index, canonical name, or local alias. Thus,  , and   (an old name for the File namespace) all return "    ". On a wiki where the content language is French,  is also valid, but   (the localisation of "File" in German) is not.

is the equivalent encoded for MediaWiki URLs. It does the same, but it replaces spaces with underscores, making it usable in external links.

Ne keverd össze a lefordított névtereket az egyedi névterekkel!

Formázás
Lásd még:

Fordítás
Here are the magic words which are used as main localisation tools. Other magic words will often depend on the wiki's locale and configuration or on the chosen language: see in particular #Date and time, #Formatting, #Miscellaneous. More magic words are added by the.

The usage of these magic words can be very complex, and the documentation is currently incomplete; there's some more info on PLURAL, GRAMMAR, GENDER.

Transclusion modifiers
usually transcludes another page, by default from the Template:namespace. These magic words modify that behavior.

Egyéb
For parser function #invoke, see w:Wikipedia:Lua.