Extensions

From Wotchipedia

Jump to: navigation, search

The Wotchipedia has several extensions that are specific to it. This page exists to document each of these extensions and how to use them.

Contents


[edit] Parser-based extensions

[edit] Links to comics

You can easily link to a comic in any of the Wotch, Cheer!, El Goonish Shive, or the Accidental Centaurs using the following forms:

{{#wotch:date|Text to display}} Wotch comic for 2005-01-01
{{#egs:date|Text to display}} El Goonish Shive comic for 2005-01-01
{{#cheer:date|Text to display}} Cheer comic for 2005-01-01
{{#ac:date|Text to display}} Accidental Centaurs comic for 2005-01-01

For dates, you must specify them in either YYYY-MM-DD or YYYYMMDD form. You may also specify today or current or last instead of a date to link to the most recent comic; or you may specify first to link to the first comic.

You can leave out the text to display part, writing it as {{#wotch:20031121}}, for example; if you do this, the parser will insert a suitable title: the Wotch on Nov 21 2003


[edit] Easy question-and-answer sections

Sometimes, the best way to communicate is with a FAQ. We have special markup that makes writing FAQs easy:

{{#qa:Question?|Answer.}}

{{#qa:What's the price of tea in China?

|Three yuan per deciliter.}}
  1. Question?
    Answer.

  2. What's the price of tea in China?
    Three yuan per deciliter.

[edit] ParserFunctions

We have installed the full ParserFunctions and Expr extensions, which allow inline conditionals and expression evaluation. These are not for the timid, but they're very powerful if used right, and we use them fairly heavily in our templates. You can learn more about these extensions at MediaWiki's page on them.

[edit] Links to Wikipedia

Because it can be helpful to do so, we have a quick and easy way to link to articles on Wikipedia. Simply type the following:

{{#wp:Article}}

This appears like this: Article

If you need to have different text than the title of the Wikipedia article itself, you can use the <tt>|</tt> separator to do that, just as with internal wiki links:

{{#wp:Article|Something or other}}

This appears like this: Something or other


[edit] Tag-based extensions

[edit] Spoiler-free sections

Webcomics, like many forms of entertainment, have special needs when represented in encyclopedic form, in that their entries must describe the storyline or characters without spoiling it for people who haven't seen the entire canon yet. We have added an extension that allows you to have spoiler-free sections that can be "folded out" to yield the full form of the text.

To generate a spoiler-free section, follow this model:

<spoiler>
  <short>Some short text that is safe for everyone.</short>
  <long>Some long text that could spoil the storyline.</long>
</spoiler>

You can put as much or as little content between the <short> and <long> tags as you want. This example appears to the viewer as:

Some short text that is safe for everyone. [spoiler...]Some long text that could spoil the storyline. [...hide spoiler]


If you need to change the [more] and [less] links to display some other text, you can do that inside the <spoiler> tag:

<spoiler more="apple" less="orange">
  <short>Some short text that is safe for everyone.</short>
  <long>Some long text that could spoil the storyline.</long>
</spoiler>

This appears to the viewer as:

Some short text that is safe for everyone. [apple]Some long text that could spoil the storyline. [orange]


There is no practical limit to the number of times you can use the <spoiler> tag on a page; however, it should be used judiciously so as not to confuse your readers.


[edit] Expanding sections

There are times (such as in the glossary) where it is convenient to have a short text description that can be expanded by the user for further detail, where the <spoiler> tag would be overcomplicated for the purpose. A special tag, the <more> tag, is provided to support this.

To generate expanding text, follow this model:

This is the regular text.  <more>This appears after you click more.</more>

You can put as much or as little content inside the <more> tag as you want. This example appears to the viewer as:

This is the regular text. [more...]This appears after you click more. [...less]

There is no practical limit to the number of times you can use the <more> tag on a page; however, it should be used judiciously so as not to confuse your readers.

Views
Personal tools