Difference between revisions of "Template:Sec link auto"

From Self-sufficiency
Jump to: navigation, search
(Renaming parameter "image=yes/no" to "padlock=yes/no" since that is clearer.)
m (11 revisions from wikipedia:Template:Sec link auto)
(2 intermediate revisions by 2 users not shown)
Line 3: Line 3:
 
   | yes    <!--Supress CSS icon, to not get double icon-->
 
   | yes    <!--Supress CSS icon, to not get double icon-->
 
   | no = <span class="plainlinks">
 
   | no = <span class="plainlinks">
   }}[https://secure.wikimedia.org/{{#switch: {{lc: {{{1|}}} }}
+
   }}[{{sec link/secure url
   | wikipedia | w = wikipedia/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   | project = {{{1|}}}
   | wiktionary | wikt = wiktionary/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   | pagename = {{{2|}}}
   | wikinews | n = wikinews/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   | lang = {{{lang|}}}
   | wikibooks | b = wikibooks/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   | query = {{{query|}}}
   | wikiquote | q = wikiquote/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   | anchor = {{{anchor|}}}
   | wikisource | s = wikisource/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   }} {{sec link/text
  | oldwikisource = wikipedia/sources
+
   | project = {{{1|}}}
   | wikispecies | species = wikipedia/species
+
   | pagename = {{{2|}}}
  | wikiversity | v = wikiversity/{{#if:{{{lang|}}}|{{{lang}}}|{{CONTENTLANG}}}}
+
   | text = {{{3|}}}
   | wikimedia | foundation | wmf = wikipedia/foundation
+
   | lang = {{{lang|}}}
  | commons = wikipedia/commons
+
  | query = {{{query|}}}
  | meta | metawikipedia | m = wikipedia/meta
+
  | anchor = {{{anchor|}}}
  | strategy = wikipedia/strategy
+
  | incubator = wikipedia/incubator
+
  | mw = wikipedia/mediawiki
+
  | nost = wikipedia/nostalgia
+
  | testwiki = wikipedia/test
+
  | #default = wikipedia/{{#if:{{{1|}}}|{{{1}}}|{{CONTENTLANG}}}}    <!-- Other language edition -->
+
  }}/wiki/{{PAGENAMEE:Template:{{{2|}}} }}{{#if:{{{query|}}}
+
   | ?{{{query|}}}
+
  | {{#if:{{{anchor|}}}
+
    | &#35;{{anchorencode:{{{anchor}}} }}
+
    }}
+
  }} {{#if: {{{3|}}}
+
   | {{{3}}}
+
  | {{#if: {{{1|}}} | {{{1}}} | {{CONTENTLANG}} }}:{{#if: {{{lang|}}}
+
    | {{{lang}}}:
+
    }}{{#if:x| {{{2|}}} }}{{#if:{{{query|}}}
+
    | ?{{{query|}}}
+
    | {{#if:{{{anchor|}}}
+
      | &#35;{{{anchor}}}
+
      }}
+
    }}
+
 
   }}]{{#switch: {{lc: {{{padlock|}}} }}
 
   }}]{{#switch: {{lc: {{{padlock|}}} }}
 
   | no = </span>
 
   | no = </span>
Line 43: Line 22:
  
 
| <!--Not on the secure server, make a normal link-->
 
| <!--Not on the secure server, make a normal link-->
   {{#if:{{{query|}}}
+
   {{#if: {{{query|}}} {{{lang|}}}
   | <!--Make a query link-->
+
   | <!--Make a full url link, needed when query or lang-->
     <span class="plainlinks">[{{fullurl: {{#if:{{{1|}}}|{{{1}}}|{{CONTENTLANG}}}}:{{#if: {{{lang|}}}
+
     <span class="plainlinks">[{{sec link/normal url
      | {{{lang}}}:
+
    | project = {{{1|}}}
      }}{{#if:x| {{{2|}}} }}
+
    | pagename = {{{2|}}}
     }}?{{{query|}}} {{#if: {{{3|}}}
+
    | lang = {{{lang|}}}
     | {{{3}}}
+
    | query = {{{query|}}}
     | {{#if:{{{1|}}}|{{{1}}}|{{CONTENTLANG}}}}:{{#if: {{{lang|}}}
+
    | anchor = {{{anchor|}}}
      | {{{lang}}}:
+
     }} {{sec link/text
      }}{{#if:x| {{{2|}}} }}?{{{query|}}}
+
    | project = {{{1|}}}
 +
     | pagename = {{{2|}}}
 +
     | text = {{{3|}}}
 +
    | lang = {{{lang|}}}
 +
    | query = {{{query|}}}
 +
    | anchor = {{{anchor|}}}
 
     }}]</span>
 
     }}]</span>
 
   | <!--Make a normal link-->
 
   | <!--Make a normal link-->
     [[:{{#if:{{{1|}}}|{{{1}}}|{{CONTENTLANG}}}}:{{#if: {{{lang|}}}
+
     [[:{{sec link/normal link
     | {{{lang}}}:
+
    | project = {{{1|}}}
    }}{{#if:x| {{{2|}}} }}{{#if:{{{anchor|}}}
+
     | pagename = {{{2|}}}
     | &#35;{{{anchor}}}
+
     | anchor = {{{anchor|}}}
     }}|{{#if: {{{3|}}}
+
     }}|{{sec link/text
     | {{{3}}}
+
     | project = {{{1|}}}
     | {{#if:{{{1|}}}|{{{1}}}|{{CONTENTLANG}}}}:{{#if: {{{lang|}}}
+
     | pagename = {{{2|}}}
      | {{{lang}}}:
+
    | text = {{{3|}}}
      }}{{#if:x| {{{2|}}} }}{{#if:{{{anchor|}}}
+
    | anchor = {{{anchor|}}}
      | &#35;{{{anchor}}}
+
      }}
+
 
     }}]]
 
     }}]]
 
   }}
 
   }}

Revision as of 21:23, 29 September 2010

Main Page