Help:Wiki Editing Syntax Guide: Difference between revisions

From NDWiki
Jump to navigation Jump to search
(→‎Templates: Change text to "Missing" template)
m (Update link: Help:Contributing -> Help:Introductory guide)
 
(5 intermediate revisions by the same user not shown)
Line 33: Line 33:


== Moving Pages ==
== Moving Pages ==
On the top of an article is the Move button. This will prompt you for a new name for the article, and gives the equivalent of a [[Help:Contributing#The Summary Bar, Minor & Major Edits|summary bar]] to explain why. Note that you cannot move Categories, and you cannot move an article to a category. In these cases, you'll simply have to Edit the page, copy all of it, and Paste it into a [[Help:Wiki Editing Syntax Guide#Creating a New Category|newly created Category]] or [[Help:Wiki Editing Syntax Guide#Creating a New Page|newly created Page]], depending on which way you're going with that. Be sure to set up appropriate [[Help:Wiki Editing Syntax Guide#Redirects|redirects]], fix links, and most of all, please leave a thorough note about the Edit History of the original page.
On the top of an article is the Move button. This will prompt you for a new name for the article, and gives the equivalent of a [[Help:Introductory guide#The Summary Bar, Minor & Major Edits|summary bar]] to explain why. Note that you cannot move Categories, and you cannot move an article to a category. In these cases, you'll simply have to Edit the page, copy all of it, and Paste it into a [[Help:Wiki Editing Syntax Guide#Creating a New Category|newly created Category]] or [[Help:Wiki Editing Syntax Guide#Creating a New Page|newly created Page]], depending on which way you're going with that. Be sure to set up appropriate [[Help:Wiki Editing Syntax Guide#Redirects|redirects]], fix links, and most of all, please leave a thorough note about the Edit History of the original page.


=== Redirects ===
=== Redirects ===
Line 48: Line 48:


== Deleting Pages ==
== Deleting Pages ==
For obvious reasons, you can't fully delete an article as a wiki user. However if you want to get rid of an entire page (e.g. one you accidentally created), you can move it into the "Articles for Deletion" category by adding the following category link to the article: <nowiki>{{afd}}</nowiki> where it's stowed safely, out of the way, and can eventually be deleted by administrators. Also remove any other categories from the page, since the article should no longer be listed on those categories.
For obvious reasons, you can't fully delete an article as a wiki user. However if you want to get rid of an entire page (e.g. one you accidentally created), you can add the following template to the top of the article: {{tl|deleteme}}. The article is then added to the [[:Category:Articles for Deletion]] and it can eventually be deleted by a administrator.
 


== Links ==
== Links ==
Line 61: Line 60:
  <nowiki>[[Article Name]]</nowiki>
  <nowiki>[[Article Name]]</nowiki>


For, example, <nowiki>[[Help:Contributing]]</nowiki> creates this: [[Help:Contributing]]. Notice that even though the URL of the article contains underscores, your link doesn't have to (it will work with underscores, but not look as nice). By the same token, special characters do not need to use their URL codes.
For, example, <nowiki>[[Help:Introductory guide]]</nowiki> creates this: [[Help:Introductory guide]]. Notice that even though the URL of the article contains underscores, your link doesn't have to (it will work with underscores, but not look as nice). By the same token, special characters do not need to use their URL codes.


To make a link use a text other than the article's name, use the vertical bar symbol, |. For example, <nowiki>[[Help:Contributing|Wiki Editing Style Guide]]</nowiki> makes this: [[Help:Contributing|Wiki Editing Style Guide]].
To make a link use a text other than the article's name, use the vertical bar symbol, |. For example, <nowiki>[[Help:Introductory guide|Wiki Editing Style Guide]]</nowiki> makes this: [[Help:Introductory guide|Wiki Editing Style Guide]].


If you want to link to a specific section of an article, use the hash symbol, #. <nowiki>[[Help:Wiki Editing Syntax Guide#Internal|Internal Links]]</nowiki> makes this link: [[Help:Wiki Editing Syntax Guide#Internal|Internal Links]]. Note that the part after the hash symbol is identical to the [[Help:Wiki Editing Syntax Guide|Header]] of the section you are linking to.
If you want to link to a specific section of an article, use the hash symbol, #. <nowiki>[[Help:Wiki Editing Syntax Guide#Internal|Internal Links]]</nowiki> makes this link: [[Help:Wiki Editing Syntax Guide#Internal|Internal Links]]. Note that the part after the hash symbol is identical to the [[Help:Wiki Editing Syntax Guide|Header]] of the section you are linking to.
Line 71: Line 70:
  <nowiki>[[:Category:Category's Name]]</nowiki>
  <nowiki>[[:Category:Category's Name]]</nowiki>


For example, <nowiki>[[:Category:Getting Started|Getting Started]]</nowiki> gives us this link: [[:Category:Getting Started|Getting Started]]. The vertical bar and the hash symbol both work for categories as well as regular articles.
For example, <nowiki>[[:Category:Help pages|Help pages]]</nowiki> gives us this link: [[:Category:Help pages|Help pages]]. The vertical bar and the hash symbol both work for categories as well as regular articles.


If your link appears in red, like [[broken link|this]], that means you are pointing to a page that does not exist. This can be a useful way to create a page, since you can click on the link and create the page, and it's also useful for seeing that you've made a typo in a link.
If your link appears in red, like [[broken link|this]], that means you are pointing to a page that does not exist. This can be a useful way to create a page, since you can click on the link and create the page, and it's also useful for seeing that you've made a typo in a link.


This is also why your username will appear red when you first sign up for the Wiki. Write something in your User Page to fix it.  
This is also why your username will appear red when you first sign up for the Wiki. Write something in your User Page to fix it.


=== External ===
=== External ===
Line 117: Line 116:


=== Table of Contents ===
=== Table of Contents ===
A Table of Contents is automatically created when you use 3 or more headings. If the page doesn't need one, place <nowiki>__NOTOC__</nowiki> at the top of the page. To force one, use <nowiki>__TOC__</nowiki> - also note that it appears where you place this tag, so you can change where the Table of Contents appears on the page. You can also use <nowiki>{{TOCright}}</nowiki> to place the table on the right side of the page, which can be desirable if the page has a lot of headings and the table takes up a lot of space.
A Table of Contents is automatically created when you use 3 or more headings. If the page doesn't need one, place <nowiki>__NOTOC__</nowiki> at the top of the page. To force one, use <nowiki>__TOC__</nowiki> - also note that it appears where you place this tag, so you can change where the Table of Contents appears on the page. You can also use {{tl|TOCright}} to place the table on the right side of the page, which can be desirable if the page has a lot of headings and the table takes up a lot of space.
 


== Paragraphs ==
== Paragraphs ==
Line 215: Line 213:


== Templates ==
== Templates ==
{{Missing|Whole section about templates is missing}}
Templates are pages in the template namespace. This means any page beginning with "Template:", such as <nowiki>[[Template:Templatename]]</nowiki> can be used as a template. The content of a template can be added to a page by typing <nowiki>{{templatename}}</nowiki>.
 
Templates are used within articles to provide a consistent look to the messages placed into them. Changes to the look, wording, or style of the message can be implemented quickly, because templates are rendered for the reader when the article loads. In [[:Category:Templates]] you will find all templates, with some of them in subcategories.
 
:''For more details and how to use templates, see [[Help:Templates]]''.


== Signing a Page ==
== Signing a Page ==

Latest revision as of 11:26, 2 December 2008

This is where you learn how to edit an article in the Wiki! The Wiki syntax is not overly complicated or difficult, but it is unique, and so we've dedicated this article to teaching it, albeit, briefly. For more information, see the list of links in the Help page. Also, always remember that the Help page is on your Navigation box on the upper left, it's very useful.

This is a rather long guide; use the Table of Contents links to go to the section you want to learn more about, or if you're totally new and want to learn everything there is to learn, read it from top to bottom.


Editing a Page

So you want to change something in a Wiki article? Well, check out the NDWiki article first if you haven't read it yet. It explains what this wiki is about.

Alright, there's something in an article that needs fixing. Maybe it's a typo, or maybe some of the formatting got messed up. Maybe you'd like to add your opinion to a discussion. In all these cases, there are two places to look to edit the page.

First, there's the Edit button the top of the article. It's pretty hard to miss, so most people know that's there. It's great for changing the introductory paragraph of a page, or for changing multiple sections.

Next to the Edit button is a + button. That's for adding a new section, which automatically formats the "subject" of the section as a "secondary" heading (more on headings below). This can be useful, too, but doesn't always appear on a page. If it is not there, you can create a new section using Edit and Headings.

Finally, there's also an edit link next to each heading of a section. This is useful because it only shows you that section's text for editing, so there's less scrolling and searching for the text you want to change.


Creating a New Page

Without a doubt the most commonly asked question on the Wiki: How do I create a new page?

The answer begins by Searching for the page. Make sure that the page does not already exist - redundant pages cause confusion on the Wiki! If your Search finds nothing, note that on the top of the page, there is a line that says this:

There is no page titled "Your Page". You can create this page.

The red section is a link to the page you want to create - click the link, and start editing!


Creating a New Category

Categories are special pages on the Wiki that have links to other pages in a list at the end of them. These pages are automatically added to the list by putting a special code at the end of each page in the category. This makes it easy to add new pages to the category.

A new category is created by adding "Category:" to the beginning of the article's name. All articles that start with "Category:" will be categories - be careful, unnecessary categories are annoyances here at the Wiki. Only make a new category when it is warranted.


Moving Pages

On the top of an article is the Move button. This will prompt you for a new name for the article, and gives the equivalent of a summary bar to explain why. Note that you cannot move Categories, and you cannot move an article to a category. In these cases, you'll simply have to Edit the page, copy all of it, and Paste it into a newly created Category or newly created Page, depending on which way you're going with that. Be sure to set up appropriate redirects, fix links, and most of all, please leave a thorough note about the Edit History of the original page.

Redirects

Moving a page automatically creates what is called a Redirect - all links going to the old page will be forwarded to the new one. However, the Wiki will only send people to the next page - a Redirect to another Redirect won't work. Therefore, it is advised that you fix any links you can find to the new page after moving, and update any Redirects to the page.

You can create your own Redirect without moving a page with the following code:

#REDIRECT [[Correct Article Name]]

This is great for things that have different names, like an abbreviation, to make sure people are going to the right place. Note that the bit after the #REDIRECT is an Internal Link, and it must be coded like one (specifically, Categories require the leading colon).

It would also be wise to use "What links here" in your Toolbox to find what links to the article, and edit those internal links to point to the category.


Deleting Pages

For obvious reasons, you can't fully delete an article as a wiki user. However if you want to get rid of an entire page (e.g. one you accidentally created), you can add the following template to the top of the article: {{deleteme}}. The article is then added to the Category:Articles for Deletion and it can eventually be deleted by a administrator.

Links

Wikis are all about links. They're what make Wikis great. A good article needs links.

There are two types of links - internal, and external. Internal links point to another article on this Wiki; external links point to another website. Each has its own formatting.

Internal

To write an internal link, use double brackets, like so:

[[Article Name]]

For, example, [[Help:Introductory guide]] creates this: Help:Introductory guide. Notice that even though the URL of the article contains underscores, your link doesn't have to (it will work with underscores, but not look as nice). By the same token, special characters do not need to use their URL codes.

To make a link use a text other than the article's name, use the vertical bar symbol, |. For example, [[Help:Introductory guide|Wiki Editing Style Guide]] makes this: Wiki Editing Style Guide.

If you want to link to a specific section of an article, use the hash symbol, #. [[Help:Wiki Editing Syntax Guide#Internal|Internal Links]] makes this link: Internal Links. Note that the part after the hash symbol is identical to the Header of the section you are linking to.

Categories are special pages on the Wiki, and they get a somewhat special formatting - you put a colon, :, before their name, like so:

[[:Category:Category's Name]]

For example, [[:Category:Help pages|Help pages]] gives us this link: Help pages. The vertical bar and the hash symbol both work for categories as well as regular articles.

If your link appears in red, like this, that means you are pointing to a page that does not exist. This can be a useful way to create a page, since you can click on the link and create the page, and it's also useful for seeing that you've made a typo in a link.

This is also why your username will appear red when you first sign up for the Wiki. Write something in your User Page to fix it.

External

When possible, it is preferable to link to an article in the Wiki rather than link to another website, but there are certainly numerous situations where an external link is applicable. They use single brackets, like so:

[URL text]

Note that there is no vertical bar or any other symbol between the URL and the text of the link, just a space. For example, linking to the Wikipedia would be done like this: [http://www.wikipedia.org Wikipedia], Wikipedia.


Categorizing

Categories are another integral part of Wikis, and after creating a new page, "how do I add an article to a category" is the most commonly asked question. The answer is to add the following code to the article:

[[Category:Help pages]]

This will add the article to the Help pages category. Note that while it will work no matter where it is on a page, it is best to put it on the bottom, where the category links actually appear on a page, or else it will be quite difficult for the next person to find. Also, remember, this is the same formatting used for an internal (non-category) link, you need special formatting to actually link to a category rather than add the article to it.

Also, the vertical bar may be used to with the category tag, but it has quite a different effect than the vertical bar does in normal internal links - it does not change the text of the link to the category, or even the name of the article as it appears in the category. What it does is change the alphabetization of the article in the category's list. For example:

[[Category:Help pages|Aardvark]]

will cause the article to be listed under A in the category's list, as if the title of the article was Aardvark, even though the actual title of the article will appear in the list. Be aware that using capitals can confuse the Wiki - capitalize only the first letter of the first word of the new title, even if the article has more capitals than that.


Headings

Headings are larger, bolder, and often underlined text that denotes the beginning of a section. They use equal signs, =, around the heading text. There is a hierarchy of headings, as follows:

  • = Primary Heading - Big, bold, underlined - often unused =
  • == Secondary Heading - not as big, bold, and underlined - usually the biggest heading used in an article ==
  • === Tertiary Heading - big and bold, but not underlined - sub-sections of a secondary heading ===
  • ==== Minor Heading - bolded, but regular size and no underline - rarely used, a sub-section of a sub-section ====

Headings are strongly encouraged when writing an article. They automatically create a Table of Contents for a page, and they make the layout very easy to follow. They can also be linked to directly by other pages.

Horizontal Rule

Wikis can also create a line across a page using four dashes, ----. In general, it's better to create a new section with its own heading, for the sake of the Table of Contents and links, but sometimes it is preferable to simply use the line to divide sections of the page.

Example:


And some more text afterwards to show what it's like.

Table of Contents

A Table of Contents is automatically created when you use 3 or more headings. If the page doesn't need one, place __NOTOC__ at the top of the page. To force one, use __TOC__ - also note that it appears where you place this tag, so you can change where the Table of Contents appears on the page. You can also use {{TOCright}} to place the table on the right side of the page, which can be desirable if the page has a lot of headings and the table takes up a lot of space.

Paragraphs

A new paragraph is started each time you skip a line. A single Return will not affect the article's text - you need to actually skip a line in between paragraphs.

To force a Return or Line Break without skipping a line, use the HTML code, <br />.

Indentation

Paragraphs are generally indented in Talk pages, for clarity's sake. There may also be cases where indentation would be useful in an article. To do so, start the first line of a paragraph with a colon, :, like so:

:This is an indented paragraph. This is just extra text to show what happens when the paragraph is longer than one line. We have enough text now.

This is an indented paragraph. This is just extra text to show what happens when the paragraph is longer than one line. We have enough text now.

The entire paragraph will be indented, and multiple colons may be used to indent further.


Text Formatting

Text formatting in Wiki uses apostrophes or single quotes, '. These are the possibilities:

  • ''italics'' - italics
  • '''bold''' - bold
  • '''''bold-italics''''' - bold-italics

Other types of formatting can be done using standard HTML tags:

  • <s>strikethrough</s> - strikethrough
  • <u>underlined</u> - underlined


Lists

There are two types of Lists - bulleted and numbered.

Starting a new paragraph, that is, skipping a line, ends your list. In the case of bulleted lists, you can't tell, but in the case of numbered lists, it restarts your numbering and messes things up.

Lists can also be mixed.

Bulleted

A bulleted list is created using asterisks, *. Each list item starts with an asterisk. Multiple asterisks cause indented bullets (sub-points).

*Point 1
**Sub-Point A
**Sub-Point B
***Sub-Sub-Point Double-Gamma
***Sub-Sub-Point Double-Epsilon
**Sub-Point C
*Point 2

  • Point 1
    • Sub-Point A
    • Sub-Point B
      • Sub-Sub-Point Double-Gamma
      • Sub-Sub-Point Double-Epsilon
    • Sub-Point C
  • Point 2

Numbered

A numbered list is created using hash symbols, #. Each list item starts with a pound symbol. Multiple hash symbols cause indented points (sub-points).

#Point 1
##Sub-Point A
##Sub-Point B
###Sub-Sub-Point Double-Gamma
###Sub-Sub-Point Double-Epsilon
##Sub-Point C
#Point 2

  1. Point 1
    1. Sub-Point A
    2. Sub-Point B
      1. Sub-Sub-Point Double-Gamma
      2. Sub-Sub-Point Double-Epsilon
    3. Sub-Point C
  2. Point 2

Mixed

Using a combination of asterisks and hash symbols is also possible.

#Point 1
#*Sub-Point A
#*Sub-Point B
#*#Sub-Sub-Point Double-Gamma
#*#Sub-Sub-Point Double-Epsilon
#*Sub-Point C
#Point 2

  1. Point 1
    • Sub-Point A
    • Sub-Point B
      1. Sub-Sub-Point Double-Gamma
      2. Sub-Sub-Point Double-Epsilon
    • Sub-Point C
  2. Point 2


Templates

Templates are pages in the template namespace. This means any page beginning with "Template:", such as [[Template:Templatename]] can be used as a template. The content of a template can be added to a page by typing {{templatename}}.

Templates are used within articles to provide a consistent look to the messages placed into them. Changes to the look, wording, or style of the message can be implemented quickly, because templates are rendered for the reader when the article loads. In Category:Templates you will find all templates, with some of them in subcategories.

For more details and how to use templates, see Help:Templates.

Signing a Page

Signing a page is very simple, and very important to discussions. Simply type four tildes, ~~~~ to insert your name, as a link to your user page, plus the date and time. Three tildes will insert just your name (as a link), but we would prefer you use four so we know when you posted.


Reverting

If you feel a change to a page was unwarranted or malicious (e.g. spamming or vandalism), you can easily revert to an earlier version of the page. Either in the difference view (via recent changes) or in the history panel, click on the date of the revision of the article you want to revert to. Then edit that page. You will get a warning that you are not editing the most current version. Ignore it and save, noting "revert" on the summary line. Again, it is in the spirit of the Wiki to edit other peoples contributions and to have your own edited, so use this option sensibly.

Moving

If a page has been maliciously moved you can return it to its original location with the Move tab (at the very top of the page). Just click on it and follow the (short!) instructions on that page. Please make sure to move the page before editing the original page. If the page cannot be moved back (a new edit history on the original page, etc.) please make a note on the Administration Noticeboard.


Conclusion

Well, that's the end of this! The Wikipedia help page has many more useful hints on the Wiki syntax. If you have any questions, please feel free to ask in the Talk page! And remember to use indentation and to sign your post!



(This text was initially a reworked copy from Baron's Bazaar Diablopedia Help:Wiki Editing Syntax Guide)