Wikicode

Wikicode
Wikicode is the strange syntax used by all wikipedias including this one. If you don't know it and are prepared to learn, continue reading. Otherwise, you can read the Wikipedia help page Here, or read the MediaWiki help page here.

This page is meant to be a much shorter list than one you would find on wikipedia, and also meant for some of our own internal templates or similar tools. Really, this will be some kind of list of some basic/advanced formatting techniques and how to use them.

Page Links
Page links are important because without them, finding pages becomes too hard. Linking to other pages minimizes the total amount of information needed on one page, but also chains pages together for ease of access. Note, any time a page has spaces in the title, they must be replaced with underscores {_} The easiest method to link to another page on our wiki is to use A_page_name. For example:

But lets say you want to link to a specific header or part of the page. Instead, we add a # symbol with the header name. like this: Name_of_page. An example:

Alternatively, you can use an on your page. The Anchor is a template that creates an invisible anchor on the page for linking. All you do is type, and all you need to do is make a link to the anchor. See the templates section for more info. An example:

In many cases, we don't want the actual page name to be in the link we make. So now we use Name_of_link. An example:

Redirecting pages
In some cases, creating a blank page to redirect to a similar named page or object is helpful. This especially helps when using the search function on the wiki. To make a redirect, create a new page of the word you need redirected, and only enter  #REDIRECT page_to_redirect_to . This makes it so whenever someone loads the page, they will be automatically redirected to the indicated page.

Headers
Headers separate the page into their respective sections (duh). As referenced earlier, headers can be linked to directly using the # symbol with the header name combined with the page name. ( PageName ) Headers are created by using the equals symbol (=) before and after a header name. For example: {| class="wikitable" | style="text-align: center;" ! This || Gives us this
 * =Heading= ||
 * =Heading= ||

Heading

 * }

If you want to make a sub-section, all you have to do is add another set of equals (=) symbols.

Just
==Just==

Like
===Like===

This
====This====

Also, as you may have noticed at the top of most pages, there is a 'contents' menu. All of the headers and sub-headers are listed here for quick access.

Page Formatting
In most cases, just using the return/enter key and headers is good enough for a page. But sometimes, you just want to add some extra flare to your pages.

Text
Some text editing tools are built into the page editor. Some examples are:

Other Than Text
works similar to using the return/enter key, but sometimes works better. Forces the line of text to break off and leave space above it.

Numbering and bullet points can also be used on a page without having to space it out. They both follow the same format, but use different symbols.

Templates
Templates are exactly what they sound like; They are a predefined format for easy use. Similar to the anchor template listed earlier, templates are their own separate pages that are designed to only require variable data to be inserted. Most, if not all templates should have a detailed description of how to use it on its page. The currently used templates can be found here, and the currently unused templates can be found here. Note, just because a template is unused, doesn't mean it is useless. If you can find a use for one, use it! To use any template, you need to reference the name of it's page within double brackets –, then define the variables. A good example of a useful template is the template. The template actually uses multiple templates within itself, but I won't go into much detail about that. When you want to use the template, paste the code from the page like so:

Then your template (in this case, our item box) shows on the page like so:

Basically, all this template did was define the Name, Background Color 1 (bgcolor1), Background Color 2(bgcolor2), and the Image. The name is simply text defined by the user, and the backgrounds are colors that you pick. You can also replace the #FFEE88 with the actual name of the color like orange, red, blue, and so on. The image variable calls out the picture file on the wiki (so first you have to upload it). Capitalization and the file extension are important for this! Otherwise the code will think you want a different file. Normally when you try to use a image or similar file with wikicode, you need to define it as a file first. Depending on how the template is built, it can put the "File:" in for you, so all you have to type is the name of the file itself.

Tables
Tables are a little tricky to cover in depth without taking up a ton of space. So for more detailed information, check out Wikipedia's table page here. Here. Tables are similar to templates, mostly just because they are a type of coding that define stuff. Most templates end up using a table of some sort to make it look pretty anyways. An extremely simple table works like so:

Gives us

Each part of the code defines where it belongs and what it does. The {| and |} are the opening and closing brackets of our table, they indicate the start and the end. The class="wikitable" defines the style of the table borders. Instead, you could replace the class with border= and define the size and style of the border. The |- indicates the end of a row, and adding a new line after it will make an extra row beneath it. The ! defines the row to be a title of sorts, which also defaults the text to be centered in the box. In the case of the class="wikitable", it makes the row a different color. The || marks the end of the box, and any data past it will be in the next box over. To add more to a table, simple add a column with ||, or add a new row by making a new line and adding |- then another line and |.

And a sortable table:

Images
Unless you put an external link to an image on a image hosting site, you will be using images uploaded to the wiki. Mostly GIF and PNG formats are preferred. The best way to get an image from the game is to download the Source Code, and export the image. Images can be placed by placing. An example: When you simply call up an image, it will be in it's full sized format. Resizing the image is not simple anymore. Adding |thumb after the file name forces it to be a thumbnail size. If the image is already smaller than the thumbnail size, then the image will not be re-sized. Also, the image will be placed in a frame (which you can add without making the image a thumbnail by adding |frame instead) and default to the right side of the page. The location of the image can also be changed by adding |left or |center. Sometimes the thumb is too big or too small. So instead, you can replace |thumb with |30px, where the 30 can be any sized number (assuming you don't want it larger than an average screen). The px stands for pixels, and does not need to be changed. For some reason the wiki seems to have issues shrinking images, so I have no clue how to properly thumbnail other than uploading a separate smaller version of the image.

When any image is placed on a page, clicking the picture will take you to another page. The default setting takes you to the images page, where you can view the upload history of that specific image. By adding a |link=www.example.com or |link=Engineering, you can make the image link to another internal or external page. Also, adding text such as |text goes here adds a small pop-up dialog that shows the defined text.

Hiding/collapsing content
Add "mw-collapsed" to the class to have it start collapsed. See examples 1 and 3.

Example 2: Text
This text is collapsible.

This text is collapsible.

[Show/hide] Example 3: Section
Text

Text

== [Show/hide]  Example 3: Section == Text Text