From StrategyWiki, the video game walkthrough and strategy guide wiki
Jump to navigation Jump to search
(adding some links, cleanup)
m (Prod moved page StrategyWiki:Guide/Links to Help:Links: More appropriate name)
 
(6 intermediate revisions by 3 users not shown)
Line 2: Line 2:


There are three sorts of links on StrategyWiki:  
There are three sorts of links on StrategyWiki:  
# Internal links to other pages in the wiki.
# Internal links to pages in the wiki.
# External links to websites.
# External links to websites.
# [[StrategyWiki:Guide/Interwiki map|Inter-wiki links]] (links to other wikis).
# [[StrategyWiki:Guide/Interwiki map|Inter-wiki links]] (links to other wikis).


To add an internal link, enclose the name of the page you want to link to in double square brackets. When you save the page, you'll see the new link pointing to your page. If the page exists already, it is displayed in blue, empty pages are displayed in red or with a blue question mark at the end, depending on your [[../Preferences#Miscellanea|preferences]]. Selflinks to the current page are not transformed into URLs but are displayed in bold.
To add an internal link, enclose the name of the page you want to link to in double square brackets. When you save the page, you'll see the new link pointing to your page. If the page exists already, it is displayed in blue, empty pages are displayed in red. Selflinks to the current page are not transformed into URLs but are displayed in bold. ([[StrategyWiki:Guide/Links]])


The first letter of the target page is automatically capitalized and spaces are represented as underscores (typing an underscore in the link will have a similar affect as typing a space, but is not recommended, since the underscore will also be shown in the text).
The first letter of the target page is automatically capitalized if it isn't a subpage, and spaces are represented as underscores (typing an underscore in the link will have a similar effect as typing a space, but is not recommended, since the underscore will also be shown in the text).
* [[Main_Page]] — Not recommended
* [[Main Page]] — Recommended
 
Links to articles in namespaces other than the mainspace must be prefixed with the namespace. In other words, to link to a template, you would use <nowiki>[[Template:Welcome]]</nowiki>, not <nowiki>[[Welcome]]</nowiki>. Likewise, you would use <nowiki>[[:Category:Images]]</nowiki> rather than <nowiki>[[Images]]</nowiki>. Like the first letter of page names, the first letter of the first word after the colon in a namespace is capitalized (Template:Welcome and Template:welcome are the same link).
 
However, this does not hold true in the mainspace. When a link with a colon is made, and if the word preceding the colon is not a valid namespace, it is treated as part of the title in the mainspace. For instance, a link to [[Bully: Scholarship Edition]] goes to the mainspace because no "Bully" namespace exists (namespaces, i.e. reservations, cannot be made without modifying the mediawiki software). Therefore it is a different link than [[Bully: scholarship Edition]] (i.e. unless you use a namespace, an article's title, except for the first letter, is case sensitive).


== How to link ==
== How to link ==
Line 23: Line 29:
|<tt><nowiki>[[Main Page|different text]]</nowiki></tt>
|<tt><nowiki>[[Main Page|different text]]</nowiki></tt>
|[[Main Page|different text]]
|[[Main Page|different text]]
|-
|Extended link
|<tt><nowiki>[[Alien]]ated</nowiki></tt>
|[[Alien]]ated
|-
|Hidden parentheses
|<tt><nowiki>[[Rambo (NES)|]]</nowiki>
|[[Rambo (NES)|Rambo]]
|-
|-
|On page anchor link  
|On page anchor link  
Line 35: Line 49:
|<tt><nowiki>[[../Preferences#Math|Shortcut link]]</nowiki></tt>
|<tt><nowiki>[[../Preferences#Math|Shortcut link]]</nowiki></tt>
|[[../Preferences#Math|Shortcut link]]
|[[../Preferences#Math|Shortcut link]]
|-
|Shortcut name only
|<tt><nowiki>[[../Preferences/]]</nowiki></tt>
|[[../Preferences/]]
|-
|-
|External link
|External link
Line 66: Line 84:
|redirect
|redirect
|<tt><nowiki>#REDIRECT [[Main Page]]</nowiki></tt>
|<tt><nowiki>#REDIRECT [[Main Page]]</nowiki></tt>
| -> [[Main Page]]
| http://strategywiki.org/w/skins/common/images/redirectltr.png [[Main Page]]
|}
|}


{{Footer Nav|game=StrategyWiki:Guide|prevpage=Wiki markup|nextpage=Images}}
{{Footer Nav|game=StrategyWiki:Guide|prevpage=Wiki markup|nextpage=Images}}

Latest revision as of 02:41, 14 July 2021

There are three sorts of links on StrategyWiki:

  1. Internal links to pages in the wiki.
  2. External links to websites.
  3. Inter-wiki links (links to other wikis).

To add an internal link, enclose the name of the page you want to link to in double square brackets. When you save the page, you'll see the new link pointing to your page. If the page exists already, it is displayed in blue, empty pages are displayed in red. Selflinks to the current page are not transformed into URLs but are displayed in bold. (StrategyWiki:Guide/Links)

The first letter of the target page is automatically capitalized if it isn't a subpage, and spaces are represented as underscores (typing an underscore in the link will have a similar effect as typing a space, but is not recommended, since the underscore will also be shown in the text).

Links to articles in namespaces other than the mainspace must be prefixed with the namespace. In other words, to link to a template, you would use [[Template:Welcome]], not [[Welcome]]. Likewise, you would use [[:Category:Images]] rather than [[Images]]. Like the first letter of page names, the first letter of the first word after the colon in a namespace is capitalized (Template:Welcome and Template:welcome are the same link).

However, this does not hold true in the mainspace. When a link with a colon is made, and if the word preceding the colon is not a valid namespace, it is treated as part of the title in the mainspace. For instance, a link to Bully: Scholarship Edition goes to the mainspace because no "Bully" namespace exists (namespaces, i.e. reservations, cannot be made without modifying the mediawiki software). Therefore it is a different link than Bully: scholarship Edition (i.e. unless you use a namespace, an article's title, except for the first letter, is case sensitive).

How to link[edit]

Description You type… You get…
Internal link [[Main Page]] Main Page
Piped link [[Main Page|different text]] different text
Extended link [[Alien]]ated Alienated
Hidden parentheses [[Rambo (NES)|]] Rambo
On page anchor link [[#How to link|On page anchor link]] On page anchor link
Different page anchor link [[StrategyWiki:Guide/Preferences#Math|Different page anchor link]] Different page anchor link
Top page shortcut [[../Preferences#Math|Shortcut link]] [[../Preferences#Math|Shortcut link]]
Shortcut name only [[../Preferences/]] [[../Preferences/]]
External link http://mediawiki.org http://mediawiki.org
External link, different title [http://mediawiki.org MediaWiki] MediaWiki
External link, unnamed [http://mediawiki.org] [1]
External link, same host unnamed [http://{{SERVERNAME}}/pagename] [2]
Interwiki link [[Wikipedia:MediaWiki]] Wikipedia:MediaWiki
mailto unnamed [mailto:info@example.org] [3]
mailto named [mailto:info@example.org info] info
redirect #REDIRECT [[Main Page]] http://strategywiki.org/w/skins/common/images/redirectltr.png Main Page