Help:Using Mediawiki

From Dota 2 Wiki
Jump to: navigation, search

Mediawiki is an open source wiki software environment, originally used by Wikipedia, and is currently used by many wikis across the web. It allows for very complicated amounts of formatting and design while still allowing for the flexibility to show information in a clean and simple manner. Mediawiki has its own formatting language that can be used within pages to format and display information.

Basics[edit]

Mediawiki automatically parses text into HTML to show pages. Different kinds of formatting can be specified with various tags, similar to HTML, but also uses groups of symbols to dictate tags as well. In general, most basic HTML tags can be used within pages to accomplish similar things to Mediawiki formatting. You can preview your formatting by clicking "Show preview" at the bottom of the editing window. It's recommended that you preview your changes before you save the page, just to make sure you haven't made a mistake.

Formatting[edit]

Description Code Results When to Use
Italic text
''Italic''
Italic For emphasis, notes, or titles of works.
Bold text
'''Bold'''
Bold For introductions and important words.
Bold and Italic text
'''''Bold and italic'''''
Bold and italic For greater emphasis, or when a particular work is important to the section.
Markup Escape
<nowiki>Not '''bold'''</nowiki>
Not '''bold''' To use formatting symbols in text.
Internal Links
[[Dota 2]]
Dota 2 When linking to a page on the Dota 2 Wiki.
Wikipedia Link
[[w:Dota 2|Dota 2]]
Dota 2 For inserting a link to a Wikipedia article.
External Links
[http://www.playdota.com/ Playdota]
Playdota When linking to other pages on the internet.
At the start of a line
Section Headers
==Level 2==
===Level 3===
====Level 4====

Level 2[edit]

Level 3[edit]

Level 4[edit]

When starting a new section.

Note: Section headers are added to the Table of Contents if a page has more than 4 section headers.

Horizontal Rule
Text A
----
Text B
Text A

Text B

Rarely to separate groups of information.
Bulleted List
* A
* B
* C
  • A
  • B
  • C
When creating a list.
Numbered List
# A
# B
# C
  1. A
  2. B
  3. C
When creating a list where order matters.
Indentation
: Indented Text
:: More indentation
:::: Very indented!
Indented Text
More indentation
Very indented!
When information below is relevant specifically to information above.
"Loose" Preformatting
 Start each line with a space.
 The information is ''still'' formatted,
 but is placed in a '''neat box'''
Start each line with a space.
The information is still formatted,
but is placed in a neat box
When providing code where indentation is important. <pre></pre> is recommended, because it ignores formatting.
Images
An inline image
[[File:Drow Ranger icon.png]]
Drow Ranger icon.png For certain symbols, or adding an image into an article.
A bordered image
[[File:Drow Ranger icon.png|border]]
Drow Ranger icon.png Draws a thin line around the image. For highlighting images on a dark background.
Image resized to width
[[File:Drow Ranger icon.png|100px]]
Drow Ranger icon.png Resizes the image so that its width matches the given size. Height is adjusted proportionally. For resizing larger images (the full size image can be viewed by clicking on it.)
Image resized to height
[[File:Drow Ranger icon.png|x100px]]
Drow Ranger icon.png Resizes the image so that its height matches the given size. Width is adjusted proportionally. For resizing images where the height is important.
Thumbnail image
[[File:Drow Ranger icon.png|thumb|caption]]
caption
For most images that are related to articles, but would not fit inline.
Framed image
[[File:Drow Ranger icon.png|frame|caption]]
caption
For images that do not fit inline, but where size is important.
Floating image
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
[[File:Drow Ranger icon.png|100px|left]]TEXT TEXT TEXT
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
Drow Ranger icon.png
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
For inserting images and having text flow around them. "left" can be changed to "right to display on the right side of the screen.
Non-floating image
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
[[File:Drow Ranger icon.png|100px|none]]TEXT TEXT TEXT
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
Drow Ranger icon.png
TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT TEXT
For preventing an image from being inserted inline. "none" can be changed to "center" to center the image.
Image that links to a page
[[File:Drow Ranger icon.png|link=Drow Ranger]]
Drow Ranger icon.png For linking to articles and pages via an image.
Image that links to a website
[[File:Drow Ranger icon.png|link=http://www.playdota.c
om/heroes/drow-ranger]]
Drow Ranger icon.png For linking to an external site via an image.
Image that doesn't link anywhere
[[File:Drow Ranger icon.png|link=]]
Drow Ranger icon.png For when images are used for decoration and should not be clicked on.
Tables
A basic table
{|
| An item || An item <!-- Header -->
|-
| An item || An item <!-- Content -->
|}
An item An item
An item An item
For positioning information.

Note: due to the nature of this page, this table is formatted wrong.

Wikitables
{| class = "wikitable"
! class = "header" | An item || An item <!-- Header -->
|-
| An item || An item <!-- Content -->
|}
An item An item
An item An item
For organizing information in a table.
For more about tables, see Mediawiki, Help:Tables.
Templates
Template Link
{{tl|Hero infobox}}
{{Hero infobox}} For inserting a link to a Template without transclusion.
Comment
{{c|This is my comment}}
Pictogram comment.png This is my comment For inserting a weighted comment to an open discussion.
Hero image
{{Hero|Drow Ranger}}
Drow Ranger icon.png For inserting an inline hero image that links to the hero's page.
{{Hero|Drow Ranger|25px}}
Drow Ranger icon.png For inserting a resized hero image.
Image Tables For information on using image tables, see {{img table el}}.
Video embedding
{{#ev:youtube|-cSFPIwMEq4}}
For embedding a video

See Also[edit]

External Links[edit]