Difference between revisions of "Adriano's wikitext tips"

From ProgClub
Jump to: navigation, search
(→‎Creating Headings: Added indentation to the example to make point clearer)
Line 16: Line 16:
 
'Healthy Foods' is a subheading of 'Foods' so we add an extra equal sign, similarly 'Fruits' is a subheading of 'Healthy Foods' so we add yet another equal sign.
 
'Healthy Foods' is a subheading of 'Foods' so we add an extra equal sign, similarly 'Fruits' is a subheading of 'Healthy Foods' so we add yet another equal sign.
 
You are free to keep iterating down by using more equal signs for each subheading.
 
You are free to keep iterating down by using more equal signs for each subheading.
 +
 +
== Creating Code Boxes ==
 +
 +
Embedding text such as terminal code in a dotted box may make your wiki posts more clear and well formatted.  For example-
 +
 +
Example terminal code
 +
cd /home/user
 +
sudo apt-get install php
 +
 +
To do this, simply add a single space to the left of the text you wish to have inside the box.  The unformatted text from above would look like this, with [SPACE] representing an actual space character-
 +
 +
[SPACE]Example terminal code
 +
[SPACE]cd /home/user
 +
[SPACE]sudo apt-get install php

Revision as of 15:46, 8 March 2012

Creating Headings

Creating headings is as simple as putting your heading text inside equal signs, for example -

== My Heading ==

We use 2 equal signs as this is a subheading of the main page title, each subsequent subheading that you wish to use would include another equal sign on each side. To demonstrate this point take a look at the following example-

 == Foods ==
    === Healthy Foods ===
       ==== Fruits ====
       ==== Vegetables ====
    === Unhealthy Foods ===
       ==== Hamburgers ====
 == Drinks ==

'Healthy Foods' is a subheading of 'Foods' so we add an extra equal sign, similarly 'Fruits' is a subheading of 'Healthy Foods' so we add yet another equal sign. You are free to keep iterating down by using more equal signs for each subheading.

Creating Code Boxes

Embedding text such as terminal code in a dotted box may make your wiki posts more clear and well formatted. For example-

Example terminal code
cd /home/user
sudo apt-get install php

To do this, simply add a single space to the left of the text you wish to have inside the box. The unformatted text from above would look like this, with [SPACE] representing an actual space character-

[SPACE]Example terminal code [SPACE]cd /home/user [SPACE]sudo apt-get install php