Difference between revisions of "Template:Citation/identifier"

From Recidemia
Jump to: navigation, search
m (fixed links)
 
m (1 revision)
 
(4 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
{{#switch:{{{identifier}}}
 
{{#switch:{{{identifier}}}
 
  |arxiv={{hide in print
 
  |arxiv={{hide in print
         |[[w:arXiv|arXiv]]:[http://arxiv.org/abs/{{{input1|}}}{{{input2|}}} {{{input1|}}}{{{input2|}}}]<!--
+
         |[[arXiv]]:[http://arxiv.org/abs/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
          -->{{#if:{{{input3|}}}
 
              |&nbsp;[{{{input3|}}}]
 
              |
 
            }}
 
 
         }}<!--
 
         }}<!--
 
     -->{{only in print
 
     -->{{only in print
         |arXiv:{{{input1|}}}{{{input2|}}}<!--
+
         |arXiv:{{{input1|}}}
          -->{{#if:{{{input3|}}}
 
              |&nbsp;[{{{input3|}}}]
 
              |
 
            }}
 
 
         }}
 
         }}
 +
|asin={{hide in print
 +
        |[[Amazon Standard Identification Number|ASIN]]&nbsp;[//www.amazon.<!--
 +
    -->{{#switch: {{{input2|}}}
 +
          |ca=ca
 +
          |cn=cn
 +
          |de=de
 +
          |ed=es
 +
          |fr=fr
 +
          |it=it
 +
          |jp=co.jp
 +
          |co.jp=co.jp
 +
          |uk=co.uk
 +
          |co.uk=co.uk
 +
          |#default=com
 +
        }}/dp/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 +
      }}<!--
 +
    -->{{only in print
 +
        |ASIN&nbsp;{{{input1|}}}
 +
      }}
 +
|bibcode={{hide in print
 +
          |[[Bibcode]] [http://adsabs.harvard.edu/abs/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 +
          }}<!--
 +
      -->{{only in print
 +
          |Bibcode&nbsp;{{{input1|}}}
 +
          }}
 
  |doi={{hide in print
 
  |doi={{hide in print
       |{{#if:{{{input2|}}}
+
       |{{#ifeq:{{str left|{{{input1|}}}|3}}|10.
        |[[w:Digital object identifier|doi]]:{{{input1|}}} (inactive {{{input2|}}}) {{#ifeq: {{NAMESPACE}} | {{ns:0}}
+
        |{{#if:{{{input2|}}}
                  |[[Category:Pages with DOIs broken since {{#time: Y | {{{input2|}}} }}]]
+
          |[[Digital object identifier|doi]]:{{{input1|}}} (inactive {{{input2|}}}) <!--
                  |
+
            -->{{#ifeq:{{NAMESPACE}}|{{ns:0}}
                  }}
+
                |[[Category:Pages with DOIs inactive since {{#time: Y | {{{input2|}}} }}]]
        |[[w:Digital object identifier|doi]]:[http://dx.doi.org/{{urlencode:{{{input1|}}}}} {{{input1|}}}]
+
                |
 +
              }}
 +
          |[[Digital object identifier|doi]]:[http://dx.doi.org/{{urlencode:{{{input1|}}}}} {{#tag:nowiki|{{{input1|}}}}}]
 +
          }}
 +
        |{{citation error|nocat={{{input3|}}}|cat=Pages with DOI errors|Bad DOI specified}}
 
         }}
 
         }}
 
       }}<!--
 
       }}<!--
Line 29: Line 50:
 
         }}
 
         }}
 
       }}
 
       }}
  |asin={{hide in print
+
  |isbn={{hide in print
         |[[w:Amazon Standard Identification Number|ASIN]]&nbsp;[http://www.amazon.com/dp/{{{input1|}}} {{{input1|}}}]
+
         |[[International Standard Book Number|ISBN]]&nbsp;[[Special:BookSources/{{{input1|}}}|{{{input1|}}}]]
 +
      }}<!--
 +
    -->{{only in print
 +
        |ISBN&nbsp;{{{input1|}}}
 +
      }}
 +
|issn={{hide in print
 +
        |[[International Standard Serial Number|ISSN]]&nbsp;[//www.worldcat.org/issn/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 
       }}<!--
 
       }}<!--
 
     -->{{only in print
 
     -->{{only in print
         |ASIN&nbsp;{{{input1|}}}
+
         |ISSN&nbsp;{{{input1|}}}
 
       }}
 
       }}
|bibcode={{hide in print
 
          |[[w:Bibcode|Bibcode]]:&nbsp;[http://adsabs.harvard.edu/abs/{{{input1|}}} {{{input1|}}}]
 
          }}<!--
 
      -->{{only in print
 
          |Bibcode:&nbsp;{{{input1|}}}
 
          }}
 
 
  |jfm={{hide in print
 
  |jfm={{hide in print
       |[[w:Jahrbuch über die Fortschritte der Mathematik|JFM]]&nbsp;[http://www.zentralblatt-math.org/zmath/en/search/?q{{=}}an:{{{input1|}}}&format{{=}}complete {{{input1|}}}]
+
       |[[Jahrbuch über die Fortschritte der Mathematik|JFM]]&nbsp;[http://www.zentralblatt-math.org/zmath/en/search/?q{{=}}an:{{{input1|}}}&format{{=}}complete {{#tag:nowiki|{{{input1|}}}}}]
 
       }}<!--
 
       }}<!--
 
   -->{{only in print
 
   -->{{only in print
Line 48: Line 69:
 
       }}
 
       }}
 
  |jstor={{hide in print
 
  |jstor={{hide in print
         |[[w:JSTOR|JSTOR]]&nbsp;[http://www.jstor.org/stable/{{{input1|}}} {{{input1|}}}]
+
         |[[JSTOR]]&nbsp;[//www.jstor.org/stable/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 
         }}<!--
 
         }}<!--
 
     -->{{only in print
 
     -->{{only in print
 
         |JSTOR&nbsp;{{{input1|}}}
 
         |JSTOR&nbsp;{{{input1|}}}
 
         }}
 
         }}
  |isbn={{hide in print
+
  |lccn={{hide in print
        |[[w:International Standard Book Number|ISBN]]&nbsp;[[Special:BookSources/{{{input1|}}}|{{{input1|}}}]]
+
        |[[Library of Congress Control Number|LCCN]]&nbsp;[http://lccn.loc.gov/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
      }}<!--
+
        }}<!--
    -->{{only in print
+
    -->{{only in print
        |ISBN&nbsp;{{{input1|}}}
+
        |LCCN&nbsp;{{{input1|}}}
      }}
+
        }}
|issn={{hide in print
 
        |[[w:International Standard Serial Number|ISSN]]&nbsp;[http://www.worldcat.org/issn/{{{input1|}}} {{{input1|}}}]
 
      }}<!--
 
    -->{{only in print
 
        |ISSN&nbsp;{{{input1|}}}
 
      }}
 
 
  |mr={{hide in print
 
  |mr={{hide in print
       |[[w:Mathematical Reviews|MR]][http://www.ams.org/mathscinet-getitem?mr{{=}}{{{input1|}}} {{{input1|}}}]
+
       |[[Mathematical Reviews|MR]]&nbsp;[//www.ams.org/mathscinet-getitem?mr{{=}}{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 
     }}<!--
 
     }}<!--
 
   -->{{only in print
 
   -->{{only in print
Line 72: Line 87:
 
     }}
 
     }}
 
  |oclc={{hide in print
 
  |oclc={{hide in print
         |[[w:Online Computer Library Center|OCLC]]&nbsp;[http://www.worldcat.org/oclc/{{{input1|}}} {{{input1|}}}]
+
         |[[Online Computer Library Center|OCLC]]&nbsp;[//www.worldcat.org/oclc/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 
       }}<!--
 
       }}<!--
 
     -->{{only in print
 
     -->{{only in print
 
         |OCLC&nbsp;{{{input1|}}}
 
         |OCLC&nbsp;{{{input1|}}}
 +
      }}
 +
|ol={{hide in print
 +
      |1={{#if:{{str endswith|{{{input1|}}}|A}}
 +
          |[[Open Library|OL]][http://openlibrary.org/authors/OL{{urlencode:{{{input1|}}}}} {{{input1|}}}]
 +
          |{{#if:{{str endswith|{{{input1|}}}|M}}
 +
            |[[Open Library|OL]][http://openlibrary.org/books/OL{{urlencode:{{{input1|}}}}} {{{input1|}}}]
 +
            |{{#if:{{str endswith|{{{input1|}}}|W}}
 +
              |[[Open Library|OL]][http://openlibrary.org/works/OL{{urlencode:{{{input1|}}}}} {{{input1|}}}]
 +
              |<includeonly>[[Category:Pages with OL errors]]<span class="error">Error: Bad OL specified!</span></includeonly>
 +
            }}
 +
          }}
 +
        }}
 +
    }}<!--
 +
-->{{Only in print
 +
    |1=OL{{{id|{{{1}}}}}}
 +
  }}
 +
|osti={{hide in print
 +
        |[[Office of Scientific and Technical Information|OSTI]]&nbsp;[//www.osti.gov/energycitations/product.biblio.jsp?osti_id{{=}}{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 +
      }}<!--
 +
    -->{{only in print
 +
        |OSTI&nbsp;{{{input1|}}}
 
       }}
 
       }}
 
  |pmc={{hide in print
 
  |pmc={{hide in print
      |[[w:PubMed Central|PMC]]&nbsp;[http://www.pubmedcentral.gov/articlerender.fcgi?tool{{=}}pmcentrez&artid{{=}}{{{input1|}}} {{{input1|}}}]  
+
        |[[PubMed Central|PMC]]&nbsp;[//www.ncbi.nlm.nih.gov/pmc/articles/PMC{{{input1|}}}/?tool{{=}}pmcentrez {{#tag:nowiki|{{{input1|}}}}}]
 
       }}<!--
 
       }}<!--
 
   -->{{only in print
 
   -->{{only in print
Line 84: Line 120:
 
       }}
 
       }}
 
  |pmid={{hide in print
 
  |pmid={{hide in print
         |[[w:PubMed Identifier|PMID]]&nbsp;[http://www.ncbi.nlm.nih.gov/pubmed/{{{input1|}}} {{{input1|}}}]
+
         |[[PubMed Identifier|PMID]]&nbsp;[//www.ncbi.nlm.nih.gov/pubmed/{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 
       }}<!--
 
       }}<!--
 
     -->{{only in print
 
     -->{{only in print
 
         |PMID&nbsp;{{{input1|}}}
 
         |PMID&nbsp;{{{input1|}}}
 +
      }}
 +
|rfc={{hide in print
 +
        |[[Request for Comments|RFC]]&nbsp;[//tools.ietf.org/html/rfc{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 +
      }}<!--
 +
    -->{{only in print
 +
        |RFC&nbsp;{{{input1|}}}
 +
      }}
 +
|ssrn={{hide in print
 +
        |[[Social Science Research Network|SSRN]]&nbsp;[http://ssrn.com/abstract{{=}}{{{input1|}}} {{#tag:nowiki|{{{input1|}}}}}]
 +
      }}<!--
 +
    -->{{only in print
 +
        |SSRN&nbsp;{{{input1|}}}
 
       }}
 
       }}
 
  |zbl={{hide in print
 
  |zbl={{hide in print
         |[[w:Zentralblatt MATH|ZBL]]&nbsp;[http://www.zentralblatt-math.org/zmath/en/search/?q{{=}}an:{{{input1|}}}&format{{=}}complete {{{input1|}}}]
+
         |[[Zentralblatt MATH|Zbl]]&nbsp;[http://www.zentralblatt-math.org/zmath/en/search/?q{{=}}an:{{{input1|}}}&format{{=}}complete {{#tag:nowiki|{{{input1|}}}}}]
 
       }}<!--
 
       }}<!--
 
     -->{{only in print
 
     -->{{only in print
         |ZBL&nbsp;{{{input1|}}}
+
         |Zbl&nbsp;{{{input1|}}}
 
       }}
 
       }}
}}<noinclude>{{documentation}}</noinclude>
+
}}<noinclude>
 +
{{documentation}}
 +
</noinclude>

Latest revision as of 16:56, 15 May 2012

[edit] [history] [purge] Documentation icon Template documentation

About this template

Template:Citation/identifier is a helper template to Wikipedia's citation system. This template ties in with other templates like Template:Citation/core. Specifically, it helps render how identifiers like ASIN, ISBN, and JSTOR are rendered in references, producing a consistent look throughout the encyclopedia.

Usage

Each identifier is invoked by use of |identifier= to define the type and one or more <syntaxhighlight lang="text" enclose="none">​imput​</syntaxhighlight> parameters:

Identifier |identifier= |input1= |input2= |input3= error check
arXiv arxiv value none
ASIN asin value top-level domain; defaults to com; do not include leading dot; valid values: co.jp, co.uk, ca, cn, fr, de, it or es none
Bibcode bibcode value none
doi doi value date the DOI is broken if <syntaxhighlight lang="text" enclose="none">​true​</syntaxhighlight>, then error category is suppressed ensure doi begins with <syntaxhighlight lang="text" enclose="none">​10.​</syntaxhighlight> if not an error shows and the page is placed in Category:Pages with DOI errors
ISBN isbn value none
ISSN issn value none
JFM jfm value none
JSTOR jstor value none
LCCN lccn value none
MR mr value none
OCLC oclc value none
OL ol value none
OSTI osti value none
PMC pmc value none
PMID pmid value none
RFC rfc value none
SSRN ssrn value none
Zbl zbl value none

See also