Open main menu

Help:Magic words

This is a copy of the master help page at m:Help:Magic words. Do not edit this page. Edits will be lost in the next update from the master page. Either edit the master help page for all projects at Meta, or edit the project-specific text at Template:Ph:Magic words. You are welcome to copy the exact wikitext from the master page at Meta and paste it into this page at any time.


Editing overview

Starting a new page

  1. Page name

Referencing

  1. Links
  2. Piped links
  3. Interwiki linking
  4. Variables
  5. URLs
  6. Anchors

Formatting

  1. Formulas
  2. Lists
  3. Tables
  4. HTML in wikitext
  5. Image & File uploads
  6. Image page

Organizing

  1. Sections
  2. Templates
  3. Categories
  4. Redirects
  5. Namespaces
  6. Renaming (moving) a page

Fixing mistakes and vandalism

  1. Reverting edits
  2. Testing

Saving effort

  1. Editing shortcuts
  2. Editing toolbar
  3. Magic words

Communicating

  1. Edit summary
  2. Talk page
  3. Edit conflict
  4. Minor edit

Special characters

  1. Turkish characters
  2. Romanian characters

Extensions

  1. WikiHiero syntax — warning: lots of images! (for Egyptian hieroglyphs)
  2. EasyTimeline syntax

Frequently Asked Questions


This is an index of Magic words used in MediaWiki.

Contents

#redirectEdit

Indicates a redirect

__NOTOC__Edit

Hides the table of contents.

__FORCETOC__Edit

Always show the table of contents.

__TOC__Edit

Place the table of contents here. See also compact TOC

__NOEDITSECTION__Edit

Hide the edit links.

__START__Edit

__START__ does nothing, and it is considered a magic word only because it has an ID in MagicWord.php (MAG_START).

CURRENTMONTHEdit

A variable.

09

CURRENTMONTHNAMEEdit

A variable.

September

CURRENTDAYEdit

A variable.

24

CURRENTDAYNAMEEdit

A variable.

Monday

CURRENTYEAREdit

A variable.

2018

CURRENTTIMEEdit

A variable.

09:15

NUMBEROFARTICLESEdit

A variable.

32,499

CURRENTMONTHNAMEGENEdit

A variable.

September

PAGENAMEEdit

A variable.

Magic words

PAGENAMEEEdit

A variable.

Magic_words

NAMESPACEEdit

A variable.

Help

MSG:Edit

A template modifier. I.e. {{msg:stub}} shows

{{Stub}}


The use of msg has an effect when a template name clashes with a magic word. For example, if [[Template:CURRENTMONTHNAME]] contained "Test", then {{CURRENTMONTHNAME}} would display "September" but {{msg:CURRENTMONTHNAME}} would display "Test".

SUBST:Edit

A template modifier. Replaces the reference to the template (e.g. {{subst:template}}) with the content of the template.

This article is a stub. You can help Wikimedia by expanding it.

MSGNW:Edit

A template modifier. Causes the template source to be pasted.

So {{msgnw:stub}} outputs:


{{asbox | image = Wiki letter w.svg{{!}}link={{!}}alt= | category = Wikiquote stubs }}<noinclude> [[Category:Stub Templates]] [[it:Template:Stub]] [[ru:Шаблон:Заготовка]] [[fi:Malline:Tynkä]] </noinclude>


__END__Edit

Allows for trailing whitespace to be deliberately included in the page save.

thumbnailEdit

An image modifier.

Mediawiki

rightEdit

An image modifier.

Mediawiki

leftEdit

An image modifier.

Mediawiki

noneEdit

An image modifier.

Mediawiki

$1pxEdit

An image modifier.

Mediawiki

centerEdit

An image modifier. Can also be spelled centre.

Mediawiki

framedEdit

An image modifier. Can also be spelled enframed or frame.


Mediawiki

INT:Edit

A special template. Used for UI messages.

mainpage:
Main Page

SITENAMEEdit

A variable.

Wikiquote

NS:Edit

A special template. Gets the name of a given namespace number.

4:
Wikiquote

LOCALURL:Edit

A special template. Gets the local URL of the given page.

{{localurl:Help:Magic words|section=0}}

results into

/w/index.php?title=Help:Magic_words&section=0

LOCALURLE:Edit

A special template. Gets the local URL of the given page.

{{localurle:Help:Magic words|section=0}}

results into

/w/index.php?title=Help:Magic_words&section=0

SERVEREdit

A variable. {{SERVER}} produces //en.wikiquote.org

GRAMMAR:Edit

Useful for inflected languages to derive word forms. Usage: {{grammar:case|word}}, cases in which this could be used depend on the specific language.

E. g. in Czech language, {{grammar:1sg|Wikipedie}} outputs Wikipedie, while {{grammar:7sg|Wikipedie}} outputs Wikipedií.

__NOTITLECONVERT__Edit

? Can also be spelled __NOTC__.

Same as below but Article Title only.

__NOCONTENTCONVERT__Edit

? Can also be spelled __NOCC__.

Don't perform the content language(character & phase) conversion in article display.(eg, Chinese zh with zh_cn, zh_tw, zh_sg, zh_hk)

CURRENTWEEKEdit

A variable.

39

CURRENTDOWEdit

A variable.

1


Since v1.5Edit

CURRENTMONTHABBREVEdit

A variable, returns the abbreviation of the current month.

Sep

FULLURL:, FULLURLE:Edit

Special templates, give the full URL of the given page.

//en.wikiquote.org/wiki/Page

REVISIONIDEdit

Gives you the article or diff database

1821508

SCRIPTPATHEdit

Returns $wgScriptPath

/w

SERVERNAMEEdit

Returns $wgServerName

en.wikiquote.org

NUMBEROFFILESEdit

Returns the number of uploaded files (rows in the image table).

1

Wikiquote-specific contentEdit

Links to other help pagesEdit

Help contents - all pages in the Help namespace: Meta b: c: n: w: q: wikisource wiktionary


Reading: Overview | Go | Search | URL | Namespace | Page name | Section | Link | Backlinks | Piped link | Interwiki link | Redirect | Variable | Category
Tracking changes: Recent | (enhanced) | Related | Watching pages | Page history | Diff | User contributions | Edit summary | Minor edit
Logging in and preferences: Logging in | Preferences | User style
Editing: Overview | New page | Images/files | Image description page | Special characters | Formula | Table | EasyTimeline | Template intro | Renaming (moving) a page | Automatic conversion of wikitext | Talk page | Testing | rlc
Projects: Meta (master page) | Wikibooks | Wikicommons | Wikinews | Wikipedia | Wikiquote | Wikisource | Wiktionary
For other languages see Meta.