Category:Utility Templates

From Ravenblack CityWiki

Jump to: navigation, search

Contents

Utility Templates

These are templates that come in handy when editing code.

Documentation / Summaries

Summaries of template functions go here, in the same order as categorized, please.

Shorthand

Links

{{cl}}

Links to a category.

{{tl}}

Links to a template.

[[wikipedia:]] link

Creates a link to a page on the English Wikipedia, with optional ability to set text.

Text Styling

{{blink}}

Should never be used ;)

Produces blinking text (on some browsers), illegal for signatures according to policy.

  • {{blink|some text}}
    some text

{{c}}

Colorizes text: just type {{c|some color|text you want to change}}.

  • {{c|red|some text}}
    some text
    {{c|red|some text|yellow}}
    some text

{{s}}

"Strikes out" text by replacing text with gray underscores, making it unreadable. Strikes out text in a clean way than the <s> HTML tag, select it to reveal it.

  • {{s|some text}}
    some text

{{z}}

Changes the size of you text.

  • {{z|75%|some text}}
    some text


Textboxes

Need a textbox, or a way to display text prominently? Try these.

<code> tag

  • For smaller blocks of text, it creates a subtle inline box and displays text in a monospace font. It will stretch off the page for text that is too wide. Try {{CodeInline}} for a better box that wraps text.
    <code>some text</code>
    some text

{{Code}}

  • Similar to {{Pre}} but with slightly different colours.
    {{Code|some text}}
    some text

{{CodeInline}}

  • For smaller blocks of text, it creates an obvious inline box and displays text in a monospace font. Better than the <code> tag.
    {{CodeInline|some text}}
    some text

<pre> tag

  • For large blocks of text, it creates a box, tries to preserve formatting and automatically nowiki's text. It will stretch off the page for text that is too wide. Try {{Pre}} for a box that wraps text.
    <pre>some text</pre>
    some text

Useful Functions

Various templates that do something quite useful.

{{CustomTitle}}

  • Creates text which appears on the page where the title usually sits, so it looks like the page has a different title. This doesn't actually change the title, and will break on skins other than Monobook or UrbanDead, so use only when needed.

{{PoemCode}}

Useful for quoting code and long passages with several lines in an offset box without producing lines of text that run off the page.

{{TOCleft}}

  • Floats the table of contents to the left, allowing text to wrap around it.

{{TOCright}}

  • Floats the table of contents to the right, allowing text to wrap around it.

Wiki Syntax Escaping

Do you need to just display a character without the wiki thinking it means something special? Use these.

{{Nosubst}}

A hack that lets your sig template remain a template despite the substitute code in the preferences settings.

Personal tools
advertising