Difference between revisions of "Template:Editlink"

ADVERTISEMENT
From Diablo Wiki
Jump to: navigation, search
(Created Template)
 
m (Protected "Template:Editlink" (‎[edit=sysop] (indefinite) ‎[move=sysop] (indefinite)) [cascading])
 
(22 intermediate revisions by 4 users not shown)
Line 1: Line 1:
<noinclude>This template is created to help making a small and neat edit link for whatever page it's needed on. It uses [[Template:Editurl|Editurl]] (and also [[Template:Lancode|Lancode]]) and two variables to work. The variables are:
+
<noinclude>This template is created to help making a small and neat edit link for whatever page it's needed on. It's an advanced version of [[Template:Editurl|Editurl]]. The template uses [[Template:Lancode|Lancode]], parsing and one compulsory variable to work.  There are also four optional variables that can be used for customization. The variables are:
  
* '''1''' - Name of the article you wish to edit.
+
* '''1''' - Full name of article linked. Must use underscores ("_") in place of spaces. (compulsory)
* '''2''' - How you want the edit link to write out. Full "Edit", or just "e" for example.
+
* '''2''' - How you want the edit link to write out. Full "Edit", just an "e", or perhaps "Edit me" for example. (optional)
 +
* '''2''' - Changing to other language code than the standard for the wiki. (optional)
 +
* '''4''' - Write ''anything'' here to put link in brackets. (optional)
 +
* '''5''' - Write ''anything'' here to make text smaller and unbolded. (optional)
  
 +
It's '''very important''' to note that in order to use variable '''4 or 5''', you must use '''all''' previous variables as well (or use specific denominators) in the template string.
  
 +
{|style="border-collapse: collapse; background: #2D0606; clear:both;" width="50%"
 +
|colspan="3"|
 +
'''Example 1:'''
 +
<nowiki>{{editlink|Template:Editlink}}</nowiki>
 +
Will create:
 +
{{editlink|Template:Editlink}}
 +
 +
|colspan="3"|
 +
'''Example 2:'''
 +
<nowiki>{{editlink|Template:Editlink|edit me}}</nowiki>
 +
Will create:
 +
{{editlink|Template:Editlink|edit me}}
  
  is '''the name of the article''' including any prefixes.
+
|-
 +
 
 +
|colspan="3"|
 +
'''Example 3:'''
 +
<nowiki>{{editlink|Template:Editlink|edit me|de}}</nowiki>
 +
'''Will create:'''
 +
  {{editlink|Template:Editlink|edit me|de}}
 +
 
 +
|colspan="3"|
 +
'''Example 4:'''
 +
<nowiki>{{editlink|Template:Editlink|edit me|de|A}}</nowiki>
 +
'''Will create:'''
 +
{{editlink|Template:Editlink|edit me|de|A}}
 +
 
 +
|-
 +
|colspan="2" width="33%"|&nbsp;
 +
 
 +
|colspan="2" width="34%"|&nbsp;
 +
'''Example 5:'''
 +
<nowiki>{{editlink|Template:Editlink|edit me|de|A|A}}</nowiki>
 +
'''Will create:'''
 +
{{editlink|Template:Editlink|edit me|de|A|A}}
 +
 
 +
|colspan="2" width="33%"|&nbsp;
 +
|}
  
Example:
 
<nowiki>{{editurl|Template:Editlink}}</nowiki>
 
Will create:
 
{{editlink|Template:Editlink}}
 
  
</noinclude><includeonly><nowiki>[</nowiki><span class="plainlinks">[http://{{{3|{{lancode}}}}}.diablowiki.net/index.php?title={{{1|DiabloWiki:Sandbox}}}&action=edit {{{2|edit}}}]</span><nowiki>]</nowiki></span></includeonly><noinclude>
+
</noinclude><includeonly>{{#if: {{{5|}}}| <span style="font-size:10px; font-weight:normal;"> }}{{#if: {{{4|}}}| <nowiki>[</nowiki> }}<span class="plainlinks">[http://{{{3|{{lancode}}}}}.diablowiki.net/index.php?title={{{1|DiabloWiki:Sandbox}}}&action=edit {{{2|edit}}}]</span>{{#if: {{{4|}}}| <nowiki>]</nowiki> }}{{#if: {{{5|}}}| </span>}}</includeonly><noinclude>
  
Related templates:
+
'''Related templates:'''
* [[Template:Editurl]] - Used to create an edit url. Uses Lancode. Used in Editlink.
 
 
* [[Template:Lancode]] - It's the language code of the wiki.
 
* [[Template:Lancode]] - It's the language code of the wiki.
* [[Template:Editlink]] - Uses Editurl (and Lancode) to create a small bracketed linkbox.
+
* [[Template:Editurl]] - Used to create an edit url. Uses Lancode. Note this is the url only.
 +
* [[Template:Editlink]] - Used to create a link, linkbox or small linkbox. Uses Lancode.
  
  
 
[[Category:DiabloWiki templates]]
 
[[Category:DiabloWiki templates]]
[[Category:Templates]]</noinclude>
+
[[Category:Templates]]
 +
[[Category:Formatting templates]]</noinclude>

Latest revision as of 14:59, 2 December 2012

This template is created to help making a small and neat edit link for whatever page it's needed on. It's an advanced version of Editurl. The template uses Lancode, parsing and one compulsory variable to work. There are also four optional variables that can be used for customization. The variables are:

  • 1 - Full name of article linked. Must use underscores ("_") in place of spaces. (compulsory)
  • 2 - How you want the edit link to write out. Full "Edit", just an "e", or perhaps "Edit me" for example. (optional)
  • 2 - Changing to other language code than the standard for the wiki. (optional)
  • 4 - Write anything here to put link in brackets. (optional)
  • 5 - Write anything here to make text smaller and unbolded. (optional)

It's very important to note that in order to use variable 4 or 5, you must use all previous variables as well (or use specific denominators) in the template string.

Example 1:

{{editlink|Template:Editlink}}

Will create:

edit

Example 2:

{{editlink|Template:Editlink|edit me}}

Will create:

edit me

Example 3:

{{editlink|Template:Editlink|edit me|de}}

Will create:

edit me

Example 4:

{{editlink|Template:Editlink|edit me|de|A}}

Will create:

[edit me]
   

Example 5:

{{editlink|Template:Editlink|edit me|de|A|A}}

Will create:

[edit me]
 



Related templates: