Wikia

Pokémon Wiki

Help:Verbatim tags

Create Talk0

The use <verbatim> tag allows for wiki pages to be injected with HTML code that MediaWiki traditionally does not render, such as <a> (anchor), <script> or <style> tags.

This allows for communities to use code snippets provided by third-party providers, such as for Twitter or Facebook feeds, and integrate them into the wiki.

Contents

Prior to Use

Before use of the verbatim tag, it is important to consider whether the code snippet in question will circumvent, or otherwise bypass, disable, or override features, or in any way inject things into pages that harm users or wikis. These violate Wikia's Terms of Use and will not be tolerated. Codes that collect information about users, redirect them without warning to third-party sites, or gives users unauthorized cookies will be removed by staff and possibly lead to a global ban against your account. If you have any questions about whether or not a code snippet is appropriate for your wiki, please contact staff for assessment.

In short

Enclose the name of the MediaWiki page you want to inject in verbatim tags and leave out the "MediaWiki:" part at the beginning:

<verbatim>Name_of_MediaWiki_page</verbatim>

Step by Step

TwitterWidget
An example of the <verbatim> tag being used on Twilight's Main Page. It pulls the code from MediaWiki:TwilightTwitterWidget
TwitterRender
Continuing from the last image, Twilight's verbatim code then renders a nice looking Twitter box that incorporates nicely with the rest of their main page
  1. Write out the desired HTML code or obtain the HTML from a trustworthy third party site.
  2. Create a MediaWiki page for the code to reside on, giving it a name that describes the purpose of the code. For example, if you are trying to embed a Twitter widget into the wiki, consider naming the page MediaWiki:TwitterWidget.
  3. Place the code inside the MediaWiki page. Pay careful attention that all tags opened, such as <div> or <span>s have a corresponding closing tag (i.e. </div> or </span>).
  4. Save the MediaWiki page. More likely than not, it will not render in an aesthetically pleasing way. Don't worry about how the MediaWiki page looks, it will look better once the verbatim tag is invoked.
  5. Go to the page that you wish to include the HTML code in. You will then invoke a complete verbatim tag set (<verbatim></verbatim>) with the MediaWiki page name between the opening and closing tags. For example, if we were to have had a MediaWiki page named MediaWiki:TwitterWidget, one should add to the page:
<verbatim>TwitterWidget</verbatim>

Errors

When verbatim tags surround the name of a page that doesn't exist, for example <verbatim>Baz</verbatim>, the output is that string surrounded by greater-than and lesser-than signs (in this case <Baz>).

See Also

Photos

Add a Photo
29,122photos on this wiki
See all photos >

Recent Wiki Activity

See more >

Around Wikia's network

Random Wiki