Difference between revisions of "Template:Citation/fcite journal"

From blackwiki
Jump to navigation Jump to search
imported>Br'er Rabbit
(in /doc)
imported>Anomalocaris
m (properly close <span> ... I believe I did this right)
 
(7 intermediate revisions by 5 users not shown)
Line 1: Line 1:
<noinclude><!--
+
<noinclude>{{historical}}<!--
 
--=========================================================================
 
--=========================================================================
 
-- Template Fcite_journal - Fast footnote for author, title/URL, work, etc.
 
-- Template Fcite_journal - Fast footnote for author, title/URL, work, etc.
 
--=========================================================================
 
--=========================================================================
 
--                                (see NOTES at bottom)
 
--                                (see NOTES at bottom)
--></noinclude>{{#if:{{{ref|}}}
+
--></noinclude>{{main other|2=<span class="citation journal" {{
 +
#if:{{{ref|}}}
 
     |{{#ifeq:{{{ref}}}|harv
 
     |{{#ifeq:{{{ref}}}|harv
       |<!--then anchor authors/editors+year-->{{anchor
+
       |<!--then anchor authors/editors+year
        |CITEREF{{{last|{{{last1|{{{author1|{{{editor-last|{{{editor1-last<!--
+
      --> id="CITEREF{{anchorencode:{{
        -->|}}}}}}}}}}}}}}}<!--
+
      #if:{{{last|{{{last1|{{{author|{{{author1|}}} }}} }}} }}}
        -->{{{last2|{{{author2|{{{editor2-last|}}}}}}}}}<!--
+
      |{{{last|{{{last1|{{{author|{{{author1}}}}}}}}}}}}<!--
        -->{{{last3|{{{author3|}}}}}}<!--
+
      -->{{{last2|{{{author2|}}}}}}<!--
        -->{{{last4|{{{author4|}}}}}}<!--
+
      -->{{{last3|{{{author3|}}}}}}<!--
        -->{{{year|{{<!--else year from date/pub-date or use pub-date 2010b-->
+
      -->{{{last4|{{{author4|}}}}}}<!--
 +
    --else-->|{{{editor-last|{{{editor1-last|}}}}}}<!--
 +
      -->{{{editor2-last|}}}{{{editor3-last|}}}{{{editor4-last|}}}
 +
      }}<!--
 +
  -->{{{year|{{<!--or year from date/pub-date or use pub-date 2010b-->
 
             #if: {{{date|}}}
 
             #if: {{{date|}}}
 
             |{{
 
             |{{
Line 22: Line 27:
 
             |{{{publication-date|}}}<!--else pub like: 2010b -->
 
             |{{{publication-date|}}}<!--else pub like: 2010b -->
 
             }}<!--endif-else {date}
 
             }}<!--endif-else {date}
         -->}}}|}}<!--end-anchor-->
+
         -->}}}|}}"<!--end-anchorencode-->
       |{{anchor|{{{ref}}}}}
+
       | id="{{anchorencode:{{{ref}}}}}"
 
     }}<!--endif-else ref="harv" -->
 
     }}<!--endif-else ref="harv" -->
   }}{{
+
   }}><!--end open-span tag-->{{
 +
 
 
   #if:{{{author|}}}|<!--if author set-->{{
 
   #if:{{{author|}}}|<!--if author set-->{{
 
     #if:{{{authorlink|{{{author1-link|}}} }}}|<!--if authorlink set then
 
     #if:{{{authorlink|{{{author1-link|}}} }}}|<!--if authorlink set then
Line 47: Line 53:
 
   -->{{#if:
 
   -->{{#if:
 
       {{{last2|{{{author2|{{{coauthors|{{{coauthor|}}} }}} }}} }}}<!--if last2
 
       {{{last2|{{{author2|{{{coauthors|{{{coauthor|}}} }}} }}} }}}<!--if last2
     -->|<b/>{{{author-separator|;}}} {{{last2|<!--
+
     -->|<nowiki/>{{{author-separator|;}}} {{{last2|<!--
 
           -->{{{author2|{{{coauthors|{{{coauthor}}}}}}}}}}}}{{
 
           -->{{{author2|{{{coauthors|{{{coauthor}}}}}}}}}}}}{{
 
           #if:{{{first2|}}}|, {{{first2}}}}}{{
 
           #if:{{{first2|}}}|, {{{first2}}}}}{{
 
           #if:{{{last3|{{{author3|}}} }}}
 
           #if:{{{last3|{{{author3|}}} }}}
             |<b/>{{{author-separator|;}}} {{{last3|{{{author3}}}}}}{{
+
             |<nowiki/>{{{author-separator|;}}} {{{last3|{{{author3}}}}}}{{
 
             #if:{{{first3|}}}|, {{{first3}}} }}{{
 
             #if:{{{first3|}}}|, {{{first3}}} }}{{
 
             #if:{{{last4|{{{author4|}}} }}}
 
             #if:{{{last4|{{{author4|}}} }}}
               |<b/>{{{author-separator|;}}} {{{last4|{{{author4}}}}}}{{
+
               |<nowiki/>{{{author-separator|;}}} {{{last4|{{{author4}}}}}}{{
 
               #if:{{{first4|}}}|, {{{first4}}} }}{{
 
               #if:{{{first4|}}}|, {{{first4}}} }}{{
 
               #if:{{{last5|{{{author5|}}} }}}
 
               #if:{{{last5|{{{author5|}}} }}}
                 |<b/>{{{author-separator|;}}} {{{last5|{{{author5}}}}}}{{
+
                 |<nowiki/>{{{author-separator|;}}} {{{last5|{{{author5}}}}}}{{
 
                 #if:{{{first5|}}}|, {{{first5}}} }}
 
                 #if:{{{first5|}}}|, {{{first5}}} }}
 
               }}<!--endif last5-->{{
 
               }}<!--endif last5-->{{
 
               #if:{{{last6|{{{author6|}}} }}}
 
               #if:{{{last6|{{{author6|}}} }}}
                 |<b/>{{{author-separator|;}}} {{{last6|{{{author6}}}}}}{{
+
                 |<nowiki/>{{{author-separator|;}}} {{{last6|{{{author6}}}}}}{{
 
                 #if:{{{first6|}}}|, {{{first6}}} }}
 
                 #if:{{{first6|}}}|, {{{first6}}} }}
 
               }}<!--endif last6-->{{
 
               }}<!--endif last6-->{{
 
               #if:{{{last7|{{{author7|}}} }}}
 
               #if:{{{last7|{{{author7|}}} }}}
                 |<b/>{{{author-separator|;}}} {{{last7|{{{author7}}}}}}{{
+
                 |<nowiki/>{{{author-separator|;}}} {{{last7|{{{author7}}}}}}{{
 
                 #if:{{{first7|}}}|, {{{first7}}} }}
 
                 #if:{{{first7|}}}|, {{{first7}}} }}
 
               }}<!--endif last7-->{{
 
               }}<!--endif last7-->{{
 
               #if:{{{last8|{{{author8|}}} }}}
 
               #if:{{{last8|{{{author8|}}} }}}
                 |<b/>{{{author-separator|;}}} {{{last8|{{{author8}}}}}}{{
+
                 |<nowiki/>{{{author-separator|;}}} {{{last8|{{{author8}}}}}}{{
 
                 #if:{{{first8|}}}|, {{{first8}}} }}
 
                 #if:{{{first8|}}}|, {{{first8}}} }}
 
               }}<!--endif last8-->
 
               }}<!--endif last8-->
Line 79: Line 85:
 
   #if:{{{editor|{{{editor-last|{{{editor1-last|}}} }}} }}}<!--if editor#1a-->
 
   #if:{{{editor|{{{editor-last|{{{editor1-last|}}} }}} }}}<!--if editor#1a-->
 
   |{{#if:{{{author|{{{last|{{{last1|{{{author1|}}} }}} }}} }}}
 
   |{{#if:{{{author|{{{last|{{{last1|{{{author1|}}} }}} }}} }}}
     |<b/>{{{author-separator|;}}}&#32;}}<!--separator
+
     |<nowiki/>{{{author-separator|;}}}&#32;}}<!--separator
 
     -->{{{editor|{{{editor-last|{{{editor1-last}}}}}}}}}{{
 
     -->{{{editor|{{{editor-last|{{{editor1-last}}}}}}}}}{{
 
       #if:{{{editor1-first|}}}|, {{{editor1-first}}}
 
       #if:{{{editor1-first|}}}|, {{{editor1-first}}}
 
     }}{{
 
     }}{{
 
     #if:{{{editor2-last|}}}<!--if editor2 set-->
 
     #if:{{{editor2-last|}}}<!--if editor2 set-->
     |<b/>{{{author-separator|;}}} <!--separator
+
     |<nowiki/>{{{author-separator|;}}} <!--separator
 
       -->{{{editor2-last}}}{{
 
       -->{{{editor2-last}}}{{
 
         #if:{{{editor2-first|}}}|, {{{editor2-first}}}
 
         #if:{{{editor2-first|}}}|, {{{editor2-first}}}
 
       }}{{
 
       }}{{
 
       #if:{{{editor3-last|}}}<!--if editor3 set-->
 
       #if:{{{editor3-last|}}}<!--if editor3 set-->
       |<b/>{{{author-separator|;}}} <!--separator
+
       |<nowiki/>{{{author-separator|;}}} <!--separator
 
         -->{{{editor3-last}}}{{
 
         -->{{{editor3-last}}}{{
 
           #if:{{{editor3-first|}}}|, {{{editor3-first}}}
 
           #if:{{{editor3-first|}}}|, {{{editor3-first}}}
 
         }}{{
 
         }}{{
 
         #if:{{{editor4-last|}}}<!--if editor4 set-->
 
         #if:{{{editor4-last|}}}<!--if editor4 set-->
         |<b/>{{{author-separator|;}}} <!--separator
+
         |<nowiki/>{{{author-separator|;}}} <!--separator
 
           -->{{{editor4-last}}}{{
 
           -->{{{editor4-last}}}{{
 
             #if:{{{editor4-first|}}}|, {{{editor4-first}}} }}
 
             #if:{{{editor4-first|}}}|, {{{editor4-first}}} }}
 
         }}<!--endif {editor4-last} -->
 
         }}<!--endif {editor4-last} -->
 
       }}<!--endif {editor3-last}
 
       }}<!--endif {editor3-last}
     --><b/>{{{author-separator|;}}} eds.&#32;
+
     --><nowiki/>{{{author-separator|;}}} eds.&#32;
     |<!--else no editor2--><b/>{{{author-separator|;}}} ed.&#32;
+
     |<!--else no editor2--><nowiki/>{{{author-separator|;}}} ed.&#32;
 
     }}<!--endif {editor2-last} -->
 
     }}<!--endif {editor2-last} -->
 
   }}<!--endif {editor|editor1-last}
 
   }}<!--endif {editor|editor1-last}
 
----------------------------------------------------- Date if authors/editors
 
----------------------------------------------------- Date if authors/editors
 
-->{{
 
-->{{
   #if:{{{last|{{{author|{{{last1|{{{author1|{{{editor|{{{editor1-last|<!--
+
   #if:{{{last|{{{author|{{{last1|{{{author1|{{{editor|{{{editor-last|<!--
       -->}}} }}} }}} }}} }}} }}}
+
       -->{{{editor1-last|}}} }}} }}} }}} }}} }}} }}}
 
     |{{<!--check if date here-->
 
     |{{<!--check if date here-->
 
     #if:{{{date|{{{year|{{{month|}}} }}} }}}
 
     #if:{{{date|{{{year|{{{month|}}} }}} }}}
Line 115: Line 121:
 
         #if:{{{origyear|}}}|&#32;[{{{origyear}}}]
 
         #if:{{{origyear|}}}|&#32;[{{{origyear}}}]
 
         }}{{{sep|.}}}&#32;
 
         }}{{{sep|.}}}&#32;
       |<b/>{{{author-separator|;}}}&#32;<!--
+
       |<nowiki/>{{{author-separator|;}}}&#32;<!--
 
   -->}}<!--endif {date|year|month}
 
   -->}}<!--endif {date|year|month}
 
-->}}<!--endif {last|author|last1|author1|editor...}
 
-->}}<!--endif {last|author|last1|author1|editor...}
Line 176: Line 182:
 
           |{{{location|London}}}{{
 
           |{{{location|London}}}{{
 
             #if:{{{publisher|{{{agency|}}} }}}
 
             #if:{{{publisher|{{{agency|}}} }}}
             |<b/>: {{{publisher|{{{agency|[[Reuters]]}}}}}} }}
+
             |<nowiki/>: {{{publisher|{{{agency|[[Reuters]]}}}}}} }}
 
           |{{{publisher|{{{agency|[[Reuters]]}}}}}}
 
           |{{{publisher|{{{agency|[[Reuters]]}}}}}}
 
           }})<!--endif location-->
 
           }})<!--endif location-->
Line 239: Line 245:
 
---------------------------------------------------------- PMC / PMID / DOI
 
---------------------------------------------------------- PMC / PMID / DOI
 
-->{{
 
-->{{
#if:{{{pmc|{{{pmid|{{{doi|}}} }}} }}}
+
#if:{{{pmc|}}}{{{pmid|}}}{{{doi|}}}
 
   |{{<!--------------------------- PMC -->
 
   |{{<!--------------------------- PMC -->
 
   #if: {{{pmc|}}}
 
   #if: {{{pmc|}}}
     |{{{sep|,}}} {{citation/identifier  |identifier=pmc |input1={{{pmc}}} }}
+
     |{{{sep|.}}} {{citation/identifier  |identifier=pmc |input1={{{pmc}}} }}
 
   }}{{<!-------------------------- PMID -->
 
   }}{{<!-------------------------- PMID -->
 
   #if: {{{pmid|}}}
 
   #if: {{{pmid|}}}
Line 325: Line 331:
 
     |{{{sep|.}}}&#32;[{{{laysummary}}} Lay summary]{{
 
     |{{{sep|.}}}&#32;[{{{laysummary}}} Lay summary]{{
 
     #if: {{{laysource|}}}
 
     #if: {{{laysource|}}}
       |&nbsp;&ndash;&nbsp;''<nowiki />{{{laysource}}}<nowiki />''}}
+
       |&nbsp;&ndash;&nbsp;''<noinclude />{{{laysource}}}<noinclude />''}}
 
   }}{{
 
   }}{{
 
   #if:{{{laydate|}}}
 
   #if:{{{laydate|}}}
 
     | &#32;({{{laydate}}}) }}<!--
 
     | &#32;({{{laydate}}}) }}<!--
 
   -->.<!--end main citation
 
   -->.<!--end main citation
--------------------------------------------------------- Quote / notes
+
--------------------------------------------------------- Quote / postscript
 
-->{{
 
-->{{
   #if:{{{quote|{{{postscript|{{{notes|<!--
+
   #if:{{{quote|}}}
    -->}}} }}} }}}
+
    |&#32;"{{{quote}}}"}}{{
  |<!--then check each of the options...-->{{
+
  #if:{{{postscript|{{{notes|}}} }}}
    #if:{{{quote|}}}
+
    |&#32;{{{postscript|{{{notes}}}}}} }}<!--endif {postscript|notes}
      |&#32;"{{{quote}}}"}}{{
+
--></span><!--end citation span
    #if:{{{postscript|{{{notes|}}} }}}
 
      |&#32;{{{postscript|{{{notes}}}}}} }}
 
  }}<!--endif quote/notes set
 
 
--------------------------------------------------------- Help option
 
--------------------------------------------------------- Help option
 
-->{{
 
-->{{
Line 401: Line 404:
 
   }}
 
   }}
 
}}<!--endif unsupported parameters
 
}}<!--endif unsupported parameters
--><noinclude><!--
+
--></span>}}<noinclude><!--
 
-----------------------------------------------------------------------
 
-----------------------------------------------------------------------
 
--NOTES:
 
--NOTES:
Line 438: Line 441:
 
--12Jul12 Added parameters first1, first2, first3 but warn of last4.
 
--12Jul12 Added parameters first1, first2, first3 but warn of last4.
 
--12Jul12 Optimized check for "author" as 2 #if's (was 7).
 
--12Jul12 Optimized check for "author" as 2 #if's (was 7).
--13Jul12 Fixed by "<b/>" to allow any separator such as ";" or ":".
+
--13Jul12 Fixed by "<nowiki/>" to allow any separator such as ";" or ":".
 
--13Jul12 Added parameter "coauthor" same as plural "coauthors".
 
--13Jul12 Added parameter "coauthor" same as plural "coauthors".
 
--13Jul12 Put location/publisher in "( )" to match Cite_journal.
 
--13Jul12 Put location/publisher in "( )" to match Cite_journal.
Line 456: Line 459:
 
--22Jul12 Process omitted date 3x faster (checked before author/editor names).
 
--22Jul12 Process omitted date 3x faster (checked before author/editor names).
 
--23Jul12 For {ref}=harv, also linked by editor[1]-last or editor2-last.
 
--23Jul12 For {ref}=harv, also linked by editor[1]-last or editor2-last.
 +
--01Aug12 Set to <span class="citation journal" id="x"> to handle "ref=".
 +
--06Sep12 Used non-nested "#if:{pmc|}{pmid|}{doi|}" was {pmc |{pmid |{doi}}}.
 
-->
 
-->
{{documentation|Template:Fcite_journal/doc}}
+
{{documentation|Template:citation/fcite_journal/doc}}
 
 
[[Category:Wikipedia formatting and function templates]]
 
 
 
 
<!--PUT INTERWIKI LINKS in /doc page, not here -->
 
<!--PUT INTERWIKI LINKS in /doc page, not here -->
 
</noinclude>
 
</noinclude>

Latest revision as of 10:30, 5 January 2020

{{{title}}}.

Template documentation[view] [edit] [history] [purge]


The Template:Citation/fcite journal, as with {{Citation/fcite web}} and other templates in the Citation/fcite group, is a fast-cite alternative to {{Cite journal}}} for use in large articles. To allow extreme speed, only the basic parameter names are supported, such as "last6=" or "first6=" rather than "surname6=" or "given6=" (etc.), and "author=" but not "authormask=". For rare parameters, the original cite templates can still be used, and mixed within an article. To view parameter names, see: Template:Cite_journal/doc.

In articles which contain more than 300 formatted references, the speed of formatting a large article, during 2009, reached 30–60 seconds for logged-in users, so the Citation/fcite templates can be used to run 5x faster (6–12 seconds) when reformatting an article. Many large articles experienced similar long delays during 2009–2012, due to using numerous large templates. Also, there have been some cases where other large templates, in the same articles, have exceeded template resources, and so {{Citation/fcite_journal}} or {{Citation/fcite_web}} could be used in those articles to allow hundreds more citations without exceeding the template limits.

Examples

The operation is very similar to {{cite journal}} and related templates.

For using {{Citation/fcite_journal}}:

Markup: {{citation/fcite journal |title=Study 17 of life|journal=Top Journal|volume=9|issue=4|p=345|publisher=Acme|location=London|date=May 1999|year=1999|url= http://www.google.com|accessdate=1 June 2009}}
Result: "Study 17 of life". Top Journal (London: Acme) 9 (4), May 1999. Retrieved 1 June 2009.

Example with 3 authors, compared to {{cite journal}}:

Markup: {{citation/fcite journal |last1=Smith|first1=Joe|last2=Doe|first2=John H.|last3=Jones|first3=Mary|title=Growth of dawn creatures|journal=Life Journal|publisher=Acme|year=1980|date=June 1980|location=London|volume=6|issue=235|page=2345-47|url= http://www.science.com|accessdate=2012-07-10}}
Result: Smith, Joe; Doe, John H.; Jones, Mary (June 1980). "Growth of dawn creatures". Life Journal (London: Acme) 6 (235): 2345-47. Retrieved 2012-07-10.
Compare: {{cite journal |last1=Smith|first1=Joe|last2=Doe|first2=John H.|last3=Jones|first3=Mary|title=Growth of dawn creatures|journal=Life Journal|publisher=Acme|year=1980|date=June 1980|location=London|volume=6|issue=235|page=2345-47|url= http://www.science.com|accessdate=2012-07-10}}
Result: Smith, Joe; Doe, John H.; Jones, Mary (June 1980). "Growth of dawn creatures". Life Journal. London: Acme. 6 (235): 2345-47. Retrieved 2012-07-10.

Related templates

The various templates within the Citation/fcite group include:

See also