Skip to content
Aa
Reading appearance
Browse
Browse the wiki
Books
Characters
Houses
Places
History
Culture
More topics
Images
Television
Chapters
Timeline
Random Article
Community
Community Portal
Recent Changes
Our Sites
Westeros
Forum of Ice and Fire
Blood of Dragons MUSH
Login
Talk
Interact
Interact
Edit source
View history
More page tools
What links here
Related changes
Page information
Special pages
Editing
Help
:
Variables
Jump to:
navigation
,
search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
'''Variables''' are a type of '''Magic words''' a strings of text that Wiki software associates with a return value or function. There are three general types of magic words: *'''Variables''': these are uppercase words surrounded by double braces, ''e.g.'' '''<code><nowiki>{{FOO}}</nowiki></code>'''. As such, they look a lot like [[Help:Templates|templates]]. Note that templates use pre set ''parameters'', that are parsed and cashed once you save the page, not each time you load it. *'''Behavior switches''': these are uppercase words surrounded by double underscores, ''e.g.'' '''__FOO__''' used for adjusting the layout or behavior of the page and can often be used to specify desired omissions and inclusions in the content. *'''Parser functions''': very similar to variables, but take one or more parameters. See also [http://www.mediawiki.org/wiki/Help:Extension:ParserFunctions Help:Extension:ParserFunctions] which offers great functionality for constructing advance templates. Here are some useful magic words, for a full list see [http://www.mediawiki.org/wiki/Help:Magic_words Help:Magic words] {| class="wikitable" |- ! style="background:#A7C1F2" width=150px| Word ! style="background:#A7C1F2" | Description |- | <code><nowiki>__NOTOC__</nowiki></code> | Hides the table of contents (TOC). |- | <code><nowiki>__FORCETOC__</nowiki></code> | Forces the table of content to appear at its normal position (above the first header). |- | <code><nowiki>__TOC__</nowiki></code> | Places a table of contents at the word's current position (overriding <code><nowiki>__NOTOC__</nowiki></code>). If this is used multiple times, the table of contents will appear at the first word's position. It is possible to suppress the auto-generated section numbers, if the proper class exists locally at [[MediaWiki:Common.css]], defined as <code>.tocnumber { display: none; }</code>. |} {| class="wikitable" width=100% |- ! style="background:#A7C1F2" width=150px | Variable ! style="background:#A7C1F2" | Output ! style="background:#A7C1F2" | Description |- | <code><nowiki>{{FULLPAGENAME}}</nowiki></code> | {{FULLPAGENAME}} | Namespace and page title. |- | <code><nowiki>{{PAGENAME}}</nowiki></code> | {{PAGENAME}} | Page title. |- | <code><nowiki>{{BASEPAGENAME}}</nowiki></code> | {{BASEPAGENAME}} | Page title excluding the current subpage and namespace ("Title/foo" on "Title/foo/bar"). For more complex splitting, use <code><nowiki>{{</nowiki>#titleparts<nowiki>}}</nowiki></code> from [http://www.mediawiki.org/wiki/Help:Extension:ParserFunctions#.23titleparts ParserFunctions extension]. |- | <code><nowiki>{{SUBPAGENAME}}</nowiki></code> | {{SUBPAGENAME}} | The subpage title ("foo" on "Title/foo"). |- | <code><nowiki>{{SUBJECTPAGENAME}}</nowiki></code> | {{SUBJECTPAGENAME}} | The namespace and title of the associated subject page. |- | <code><nowiki>{{TALKPAGENAME}}</nowiki></code> | {{TALKPAGENAME}} | The namespace and title of the associated talk page. |} {{Template:WikiHelpNav}} [[Category:Help|Variables]]
Summary:
Please note that all contributions to A Wiki of Ice and Fire may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
A Wiki of Ice and Fire:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Pages included on this page:
Template:Hlist/styles.css
(
edit
)
Template:Navbar/styles.css
(
edit
)
Template:Navbox
(
edit
)
Template:Navbox/styles.css
(
edit
)
Template:WikiHelpNav
(
edit
)
Module:Arguments
(
edit
)
Module:Navbar
(
edit
)
Module:Navbar/configuration
(
edit
)
Module:Navbox
(
edit
)
Module:Navbox/configuration
(
edit
)
Module:TableTools/sandbox
(
edit
)