No categories assigned

Wikitext

Revision as of 09:57, 11 October 2019 by Mlink-rodrigue (talk | contribs) (Created page with "==What is Wikitext?== Wikitext is a simplified markup language that is used to format and structuretext and other data. While HTML is the most common markup language for web p...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

What is Wikitext?

Wikitext is a simplified markup language that is used to format and structuretext and other data. While HTML is the most common markup language for web pages, Wikitext is used in wiki systems. Like HTML, it uses tags to mark parts of tags or other data.

How do I use Wikitext?

When you edit a page, you can switch between Visual editing and source editing:

Screenshot: Visual Editor switch edit mode

Wikitext can be entered in source editing mode. When you are in visual editing mode, VisualEditor inserts Wikitext "behind the scenes". If VisualEditor doesn't format elements on a page correctly, you can always switch to source editing to correct the issues directly in Wikitext.

Examples of Wikitext

Here are some typical examples of Wikitext:

Formatting

  • This is '''bold'''
  • This is ''italic''
  • This is <u>underlined</u>

Structuring

  • This is a ==Section Heading==
  • This is an *unordered list item (first level)
  • Table: Table:
header 1 header 2
row 1, cell 1 row 1, cell 2
row 2, cell 1 row 2, cell 2

Links / Embedding:

  • Insert a link: [[Pancake|Best pancake]] - this creates a link to the page "Pancake" with the link description "Best pancake".
  • Embed an image: Images[[File:Someimage.png]] - This embeds the image someimage.png on the page.
    • embedding only happens when a link points to the "File" namespace
    • the wiki checks if preview/thumbnail can be created automatically (e.g. image formats like "png", "jpeg", "gif", "svg") and then embeds a preview into the page
    • otherwise a link will be created to the wikipage in the "File" namespace (aka "file description page")
  • Embed a file: [[Media:SomePDF.pdf]]
    • can be embedded: PDF, Tiff (needs extension)
    • cannot be embedded: Microsoft Office and Libre Office files; Shell-Scripts, ...

Magic words

Magic words are strings of text that Mediawiki associates with a return value or function. Examples are:

  • "Behavior switch", aka "Double underscore", e.g. __TOC__
  • "Variables", e.g. {{FULLPAGENAME}}
  • "Tags", e.g. <gallery>
  • "ParserFunctions", e.g. {{#ifeq:x|y|true|false}}

External resources

For a more complete list of all Wikitext tags, you can refer to the Wikimedia page https://meta.wikimedia.org/wiki/Help:Wikitext_examples.

Attachments

Discussions