Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

User:Evon R'al/Wiki coding notes: Difference between revisions

From EVE University Wiki
m Add info about space versus underscore in links.
m Reorganize. Typo's. Add some info.
Line 28: Line 28:
* [[mediawikiwiki:Help:Signatures]]
* [[mediawikiwiki:Help:Signatures]]


== Code snippets ==
== Wiki mark-up ==
=== Small stuf ===
No more mineable asteroids in missons:
{{Code|<nowiki>Various mission site locations have had mineable asteroids replaced with cosmetic asteroids. (30/03/2020)
<ref>https://www.eveonline.com/news/view/patch-notes-for-march-2020-release 30/03/2020</ref></nowiki>}}
Various mission site locations have had mineable asteroids replaced with cosmetic asteroids. (30/03/2020)<ref>https://www.eveonline.com/news/view/patch-notes-for-march-2020-release 30/03/2020</ref>
 
 
{{T|Hatnote}} to link back to multi level/faction disambiguation pages:
{{Code
|<nowiki>{{hatnote|This article details the Level ?, <Faction> version of this mission. For other variants, see [[<Mission>|<Mission> (disambiguation)]].}}
</nowiki>}}
 
=== Linking ===
=== Linking ===
See also: [[mediawikiwiki:Help:Links]]
See also: [[mediawikiwiki:Help:Links]]
Line 47: Line 35:
A piped link is an internal or [[#interwiki link|interwiki]] link where the link target and link label are both specified.
A piped link is an internal or [[#interwiki link|interwiki]] link where the link target and link label are both specified.


=== Space or underscore ===
==== Space or underscore ====
The wiki software automatically changes spaces to underscores (_) in internal links (Need to check for inter wiki links). So [[Relic_and_data_sites]] and [[Relic and data sites]] are equivalent. Eliminating the need to change the underscore version into a piped link for nice readability, providing a "cleaner" source.
The wiki software automatically changes spaces to underscores (_) in internal links (Need to check for inter wiki links). So [[Relic_and_data_sites]] and [[Relic and data sites]] are equivalent. Eliminating the need to change the underscore version into a piped link for nice readability, providing a "cleaner" source.


Line 81: Line 69:
The existence of the page is still checked, but the existence of the anchor is not.<br>
The existence of the page is still checked, but the existence of the anchor is not.<br>
Note: If a non existing anchor is used the link goes to the top of the page.<br>
Note: If a non existing anchor is used the link goes to the top of the page.<br>
<code><nowiki>[[combat sites#no exist]]</nowiki></code> gives [[combat sites#no exist]], leading ot the top of the combat sites page
<code><nowiki>[[combat sites#no exist]]</nowiki></code> gives [[combat sites#no exist]], leading to the top of the combat sites page


<code><nowiki>[[#Signatures]]</nowiki></code> gives [[#Signatures]] leading to the Signatures heading on this page.
<code><nowiki>[[#Signatures]]</nowiki></code> gives [[#Signatures]] leading to the Signatures heading on this page.
Line 123: Line 111:
; Category namespace
; Category namespace
<code><nowiki>[[Category:Pilots]]</nowiki></code> gives a link to the Category category and the Pilots category in a separate box at the bottom of the page.<br>
<code><nowiki>[[Category:Pilots]]</nowiki></code> gives a link to the Category category and the Pilots category in a separate box at the bottom of the page.<br>
To get a link to the Pilots category in the text use <code><nowiki>[[:Category:Pilots]]</nowiki></code> which gives [[:Category:Pilots]]
To get a link to the Pilots category page in the text use <code><nowiki>[[:Category:Pilots]]</nowiki></code> which gives [[:Category:Pilots]]


* [https://wiki.eveuniversity.org/api.php?action=query&meta=siteinfo&siprop=namespaces&format=xml List of namespaces (In raw XML)]
* [https://wiki.eveuniversity.org/api.php?action=query&meta=siteinfo&siprop=namespaces&format=xml List of namespaces (In raw XML)]
Line 134: Line 122:
A intrawiki link to MediaWiki's help page about links looks like <code><nowiki>[[Mediawikiwiki:Help:Links]]</nowiki></code> which gives [[Mediawikiwiki:Help:Links]]
A intrawiki link to MediaWiki's help page about links looks like <code><nowiki>[[Mediawikiwiki:Help:Links]]</nowiki></code> which gives [[Mediawikiwiki:Help:Links]]


The link end and pipe tricks described at internal links work for interwiki links just as-well.
The link end and pipe tricks described at internal links work for interwiki links just as-well. And use of a label to change the presentation of a link also works.


==== External link====
==== External link====
Line 152: Line 140:


* Finally the external link rendering can be suppressed by using the CSS class {{Co|wheat|plainlinks}} making the link look like an internal one. <code><nowiki><span class="plainlinks">[https://wiki.eveuniversity.org/index.php?title=User:Evon_R%27al Evon R'al's user page]</span></nowiki></code> produces <span class="plainlinks">[https://wiki.eveuniversity.org/index.php?title=User:Evon_R%27al Evon R'al's user page]</span>
* Finally the external link rendering can be suppressed by using the CSS class {{Co|wheat|plainlinks}} making the link look like an internal one. <code><nowiki><span class="plainlinks">[https://wiki.eveuniversity.org/index.php?title=User:Evon_R%27al Evon R'al's user page]</span></nowiki></code> produces <span class="plainlinks">[https://wiki.eveuniversity.org/index.php?title=User:Evon_R%27al Evon R'al's user page]</span>
== Code snippets ==
=== Small stuf ===
No more mineable asteroids in missons:
{{Code|<nowiki>Various mission site locations have had mineable asteroids replaced with cosmetic asteroids. (30/03/2020)
<ref>https://www.eveonline.com/news/view/patch-notes-for-march-2020-release 30/03/2020</ref></nowiki>}}
Various mission site locations have had mineable asteroids replaced with cosmetic asteroids. (30/03/2020)<ref>https://www.eveonline.com/news/view/patch-notes-for-march-2020-release 30/03/2020</ref>
{{T|Hatnote}} to link back to multi level/faction disambiguation pages:
{{Code
|<nowiki>{{hatnote|This article details the Level ?, <Faction> version of this mission. For other variants, see [[<Mission>|<Mission> (disambiguation)]].}}
</nowiki>}}


=== MessageBox with logo ===
=== MessageBox with logo ===