19,344
edits
(more table help) |
(changed sample OCF links (RIP OCF); removed some niche advice on specific templates; various wording) |
||
Line 59: | Line 59: | ||
===External links=== | ===External links=== | ||
(1a) Write the following to get some text acting as an ''outgoing'' hyperlink. | (1a) Write the following to get some text acting as an ''outgoing'' hyperlink. | ||
'''['''<nowiki> | '''['''<nowiki>https://discord.com/invite/eqDMnkD here is our Discord server</nowiki>''']''' | ||
The result is: [ | The result is: [https://discord.com/invite/eqDMnkD here is our Discord server] | ||
(1b) If you omit the label text, the result will be different: | (1b) If you omit the label text, the result will be different: | ||
here '''['''<nowiki>https://discord.com/invite/eqDMnkD</nowiki>''']''' is our Discord server | |||
The result is: here [ | The result is: here [https://discord.com/invite/eqDMnkD] is our Discord server. However, this is not our usual style on this wiki; you should always label your links. | ||
(1c) You can also write URLs without any markup. Like this: | (1c) You can also write URLs without any markup. Like this: | ||
:Here is our | :Here is our Discord server: https://discord.com/invite/eqDMnkD | ||
Note that external images will appear inline if you use their bare URL like this. | Note that external images will appear inline if you use their bare URL like this. | ||
===Intrawiki links=== | ===Intrawiki links=== | ||
(2a) | "Intrawiki" refers to links to other pages on this wiki. | ||
(2a) Simply write the following to get an intrawiki link: | |||
<nowiki>[[Quotes/Consoles#STURMANDERUNG_:_Final_Stage]]</nowiki> | <nowiki>[[Quotes/Consoles#STURMANDERUNG_:_Final_Stage]]</nowiki> | ||
Line 77: | Line 79: | ||
The result is this: [[Quotes/Consoles#STURMANDERUNG_:_Final_Stage]] | The result is this: [[Quotes/Consoles#STURMANDERUNG_:_Final_Stage]] | ||
(2b) Write following to get an | (2b) Write the following to get an intrawiki link which is labeled with some text: | ||
<nowiki>[[OniSplit#Download_links|You can download OniSplit here]]</nowiki> | <nowiki>[[OniSplit#Download_links|You can download OniSplit here]]</nowiki> | ||
Line 83: | Line 85: | ||
The result is this: [[OniSplit#Download_links|You can download OniSplit here]] | The result is this: [[OniSplit#Download_links|You can download OniSplit here]] | ||
This kind of link | This kind of link spares you from writing '''<nowiki>http://wiki.oni2.net/</nowiki>OniSplit#Download_links''', and also allows various features of the wiki to work properly, such as "What links here" and the [[Special:LonelyPages|orphaned pages]] list. | ||
===Interwiki links=== | ===Interwiki links=== | ||
You can link to pages on [[wikt:Wiktionary:Main_Page|Wiktionary]], | You can link to pages on wikis in the Wikimedia family, e.g. [[wikt:Wiktionary:Main_Page|Wiktionary]], [[wp:Main_Page|Wikipedia]] and [[metawikimedia:Main_Page|Meta-Wiki]], as if they were pages of our own wiki by adding the shortcuts '''<nowiki>wiktionary:</nowiki>''', '''<nowiki>wikipedia:</nowiki>''' and '''<nowiki>metawikimedia:</nowiki>''' within double brackets. When you make an interwiki link, the outbound link icon changes from an upward arrow to a sideward arrow to show that you are linking to a fellow wiki, not some random web site. | ||
An example of using an interwiki prefix would be '''<nowiki>[[wikipedia:Test]]</nowiki>''', which produces [[wikipedia:Test]] | An example of using an interwiki prefix would be '''<nowiki>[[wikipedia:Test]]</nowiki>''', which produces [[wikipedia:Test]]. You can supply label text using the syntax '''<nowiki>[[wikipedia:Test|Test]]</nowiki>''' to get rid of that pesky prefix in the final markup: [[wikipedia:Test|Test]]. These prefixes accept language codes, so you could use the markup '''<nowiki>[[wikipedia:de:Test|Test]]</nowiki>''' to link to the German article [[wikipedia:de:Test|Test]]. | ||
All of the Wikimedia Foundation's projects have prefixes available for linking to them. Also note that we have handy shortcuts for the two most-used prefixes; '''wikipedia:''' can be shortened to '''wp:''' and '''wiktionary:''' can be shortened to '''wikt:'''. The complete list of currently supported interwiki links can be obtained by clicking [https://wiki.oni2.net/w/api.php?action=query&meta=siteinfo&siprop=interwikimap here]. | All of the Wikimedia Foundation's projects have prefixes available for linking to them. Also note that we have handy shortcuts for the two most-used prefixes; '''wikipedia:''' can be shortened to '''wp:''' and '''wiktionary:''' can be shortened to '''wikt:'''. The complete list of currently supported interwiki links can be obtained by clicking [https://wiki.oni2.net/w/api.php?action=query&meta=siteinfo&siprop=interwikimap here]. | ||
Line 108: | Line 97: | ||
==Images and categories== | ==Images and categories== | ||
To place an image, you type its name inside of double brackets | To place an image, you type its name inside of double brackets preceded by "Image:", e.g. <code><nowiki>[[Image:TXMPPOSTER3.png]]</nowiki></code>. This markup will be replaced by the named image. If you only want to link to an image, not display it, you type <code><nowiki>[[:Image:TXMPPOSTER3.png]]</nowiki></code> to get [[:Image:TXMPPOSTER3.png]]. | ||
Categories work the same way. Every page on the wiki should be placed into at least one category using this kind of markup at the end of the page: <code><nowiki>[[Category:Policies and documentation]]</nowiki></code>. This will cause the name of the category to appear at the bottom of the page. However, if you only want to link to a category page, not place the current page into that category, you use the same technique as linking to an image page: <code><nowiki>[[:Category:Policies and documentation]]</nowiki></code> gives you [[:Category:Policies and documentation]]. To see what categories are available, you can look at the [[Site Map]]. | Categories work the same way. Every page on the wiki should be placed into at least one category using this kind of markup, placed at the end of the page: <code><nowiki>[[Category:Policies and documentation]]</nowiki></code>. This will cause the name of the category to appear at the bottom of the page. However, if you only want to link to a category page, not place the current page into that category, you use the same technique as linking to an image page: <code><nowiki>[[:Category:Policies and documentation]]</nowiki></code> gives you [[:Category:Policies and documentation]]. To see what categories are available, you can look at the [[Site Map]]. | ||
==Templates and transclusion== | ==Templates and transclusion== | ||
Text can be "transcluded" from one place on the wiki to another using <nowiki>{{this markup}}</nowiki>. Transclusion means that whenever the original text is updated, so is the text inserted in place of the page link enclosed in double-braces. | Text can be "transcluded" from one place on the wiki to another using <nowiki>{{this markup}}</nowiki>. Transclusion means that whenever the original text is updated, so is the text inserted in place of the page link enclosed in double-braces. Transclusion is most commonly used in order to place templates on a page. [[:Category:Templates|Here's a list of our wiki's templates.]] Click on one, and then click on "What links here": you should see a list of pages, each one probably followed by "(transclusion)". Look at the wiki markup for those pages to see how the template was utilized on the page. | ||
Templates are not a special kind of wiki page; they're simply a term that we use to refer to pages that are meant to be transcluded. | Templates are not a special kind of wiki page; they're simply a term that we use to refer to pages that are meant to be transcluded, and which often use magic words (terms with special meaning to the MediaWiki parser) to provide logic (but again, this logic can be used on any page). Templates usually provide a standardized format for something like a table, header or footer, e.g. [[:Template:OBD File Footer]]. You should familiarize yourself with our templates if you plan to do a decent amount of editing; they are not only time-savers but they also help editors make their edits fit in with OniGalore standards, and make it easier to change large amounts of wiki text at once. | ||
==Tables== | ==Tables== |