Help:Wikicode: Difference between revisions

1,903 bytes added ,  28 October 2010
→‎Links: is there a complete list of these somewhere? we don't seem to have Special:Interwiki. It is more important to teach template:p than template:ap
(Someone else wanna do some?)
(→‎Links: is there a complete list of these somewhere? we don't seem to have Special:Interwiki. It is more important to teach template:p than template:ap)
Line 53: Line 53:


[[Ash's Pikachu|his Pikachu]]
[[Ash's Pikachu|his Pikachu]]
===Shortlinks===
===Shortlinks===
{{main|Bulbapedia:List of link templates}}
{{main|Bulbapedia:List of link templates}}
These '''must''' be used in articles when necessary.
These '''must''' be used in articles when necessary.


Example: <code><nowiki>{{AP|Pikachu}}</nowiki></code>
Example: <code><nowiki>{{p|Pikachu}}</nowiki></code>


Will result in:
Will result in:


{{AP|Pikachu}}
{{p|Pikachu}}


Instead of:
Instead of:


[[Pikachu]]
[[Pikachu]]
===Interwiki links===
Interwiki links can be used to link to other wikis affiliated with Bulbapedia, such as [[Bulbagarden Archives]], [[Bulbanews]], Wikipedia, other members of [[Encyclopædiæ Pokémonis]], and other members of [[Nintendo Independent Wiki Alliance|NIWA]]. To link to another wiki, simply use square brackets like a normal link, but place the prefix at the start of the link.
When linking to an Encyclopædiæ Pokémonis member via this method, there must be a colon : before the prefix, or it will not link correctly.
Example:
<code><nowiki>[[wp:Pokémon|Pokémon]]</nowiki></code>
Will make:
[[wp:Pokémon|Pokémon]]
'''Note''': most interwiki prefixes have identically named templates, so to link to Wikipedia's article on Pokémon, it can be achieved by typing <code><nowiki>[[wp:Pokémon|Pokémon]]</nowiki></code> or <code><nowiki>{{wp|Pokémon}}</nowiki></code>.
====Incomplete list of interwiki prefixes====
{|
|[[Bulbagarden Archives]]
|a
|-
|[[PokéWiki]]
|:de
|-
|[[Pokéteca]]
|:es
|-
|[[Poképédia]]
|:fr
|-
|[[Pokémon Central Wiki]]
|:it
|-
|[[Pokémon Wiki]]
|:ja
|-
|[[Lylat Wiki]]
|lw
|-
|[[Metroid Wiki]]
|met
|-
|MediaWiki
|mw
|-
|[[Bulbanews]]
|n
|-
|[[Pikipedia]]
|pk
|-
|[[Wikinezka]]
|:pl
|-
|[[LANDpedia]]
|:pt
|-
|[[Super Mario Wiki]]
|smw
|-
|[[StrategyWiki]]
|sw
|-
|Wiktionary
|wiktionary
|-
|[[WiKirby]]
|wk
|-
|Wikipedia
|wp
|-
|[[Wars Wiki]]
|ww
|-
|[[Zelda Wiki]]
|zw
|}
===Incomplete link===
When using interwiki links or linking to pages not in the main namespace, typing <code><nowiki>[[prefix:Link name|]]</nowiki></code> causes it to be substituted by <code><nowiki>[[prefix:Link name|Link name]]</nowiki></code> after saving the page.
Example:
<code><nowiki>[[Template:Welcome|]]</nowiki></code>
Will be substituted to:
<code><nowiki>[[Template:Welcome|Welcome]]</nowiki></code>
Will make:
[[Template:Welcome|Welcome]]


===External link===
===External link===
To link to a page outside Bulbapedia and give it a name, write the URL, a space, the name, then finally put brackets around everything, like so: put <nowiki>[</nowiki> before the url and name and <nowiki>]</nowiki> after it
To link to a page outside Bulbapedia and give it a name, write the URL, a space, the name, then finally put brackets around everything, like so: put <nowiki>[</nowiki> before the url and name and <nowiki>]</nowiki> after it.


Example:
Example:


<code><nowiki>[http://wikipedia.org nifty pages]</nowiki></code>
<code><nowiki>[http://www.pokemon.com/us/ Official Pokémon website]</nowiki></code>


Will make:
Will make:


[http://wikipedia.org nifty pages]
[http://www.pokemon.com/us/ Official Pokémon website]
 


To link to an external page without giving it specific name, simply write the URL without any brackets or spaces, like so: http://www.pokemon.com/Dungeon/PersonalityTest
To link to an external page without giving it a specific name, simply write the URL without any brackets or spaces, like so: http://www.pokemon.com/us/


However, an external picture not in the archives may also be placed with exactly the same technique:
However, an external picture not in the archives may also be placed with exactly the same technique:
Line 87: Line 180:
Result:http://archives.bulbagarden.net/w/upload/0/0a/025.png
Result:http://archives.bulbagarden.net/w/upload/0/0a/025.png


Note that it is not recommended to do this in mainspace articles.
Note that this is not to be done in mainspace articles.


==Table==
==Table==