Template:Cite book: Difference between revisions

From WikiMD's Wellness Encyclopedia

No edit summary
No edit summary
Line 1: Line 1:
<includeonly>
<includeonly>
{{#if:{{{title|}}} | <!-- Ensure at least a title is provided -->
{{#if:{{{title|}}} |
   {{#if:{{{author|}}} | {{#ifeq:{{{last|}}}|{{{author|}}}| | {{{last}}}, }} }}
   {{#if:{{{last|}}} | {{{last}}}{{#if:{{{first|}}}|, {{{first}}}}} | {{#if:{{{author|}}}|{{{author}}}}} }},
  {{#if:{{{first|}}}|{{{first}}} }}{{#if:{{{author|}}}|{{{author}}}}},
   '''{{{title}}}''',
  {{#if:{{{coauthors|}}}|{{{coauthors}}}, }}
  {{#if:{{{journal|}}}|''{{{journal}}}''}},
   '''{{{title}}}'''{{#if:{{{url|}}}|. [{{{url}}} online version]}},  
   {{#if:{{{year|}}}|{{{year}}}, }}
   {{#if:{{{edition|}}}|{{{edition}}} edition, }}  
   {{#if:{{{volume|}}}|Vol. {{{volume}}}{{#if:{{{issue|}}}|(Issue: {{{issue}}})}}, }}
   {{#if:{{{location|}}}|{{{location}}}: }}{{#if:{{{publisher|}}}|{{{publisher}}}, }}  
   {{#if:{{{pages|}}}|pp. {{{pages}}}, }}
   {{#if:{{{year|}}}|{{{year}}}, }}  
   {{#if:{{{doi|}}}|DOI: [https://doi.org/{{{doi}}} {{{doi}}}], }}
   {{#if:{{{series|}}}|Series: {{{series}}}, }}  
   {{#if:{{{pmid|}}}|PMID: [https://pubmed.ncbi.nlm.nih.gov/{{{pmid}}} {{{pmid}}}], }}
   {{#if:{{{volume|}}}|Volume: {{{volume}}}, }}  
   {{#if:{{{pmc|}}}|PMC: [https://www.ncbi.nlm.nih.gov/pmc/articles/PMC{{{pmc}}}/ {{{pmc}}}], }}
   {{#if:{{{isbn|}}}|ISBN {{{isbn}}}, }}  
   {{#if:{{{arxiv|}}}|arXiv: [https://arxiv.org/abs/{{{arxiv}}} {{{arxiv}}}], }}
   {{#if:{{{doi|}}}|DOI: {{{doi}}}, }}  
   {{#if:{{{url|}}}|[{{{url}}} Full text], }}
   {{#if:{{{id|}}}|ID: {{{id}}}, }}  
   {{#if:{{{access-date|}}}|Accessed on: {{{access-date}}}. }}
   {{#if:{{{access-date|}}}|Accessed: {{{access-date}}}. }}
  {{#if:{{{pages|}}}|Pages: {{{pages}}}, }}  
}}
}}
</includeonly><noinclude>
</includeonly><noinclude>


== Documentation ==
== Documentation ==
This template is used to cite books in MediaWiki articles. The format dynamically includes only provided fields.
This template is used to cite journal articles. It dynamically formats citations based on the parameters provided.


=== Parameters ===
=== Parameters ===
* '''title''' – The title of the book (required).
* '''title''' – Title of the journal article (required).
* '''author''' – The author(s) of the book (optional, can use `last` and `first`).
* '''author''' – Primary author(s).
* '''coauthors''' – Coauthors, if applicable.
* '''first''' – First name(s) of the author(s).
* '''url''' – URL to the book, if available online.
* '''last''' – Last name(s) of the author(s).
* '''edition''' – Edition of the book.
* '''journal''' – Name of the journal.
* '''location''' – Location of the publisher.
* '''publisher''' – Publisher name.
* '''year''' – Year of publication.
* '''year''' – Year of publication.
* '''series''' – Series name, if applicable.
* '''volume''' – Volume of the journal.
* '''volume''' – Volume number, if part of a series.
* '''issue''' – Issue number of the journal.
* '''isbn''' – ISBN of the book.
* '''pages''' – Page range of the article.
* '''doi''' – DOI of the book.
* '''doi''' – DOI (Digital Object Identifier) of the article.
* '''id''' – Additional identifier for the book.
* '''pmid''' – PubMed ID of the article.
* '''access-date''' – Date the book was accessed online.
* '''pmc''' – PubMed Central ID of the article.
* '''pages''' – Pages referenced.
* '''arxiv''' – arXiv identifier.
* '''url''' – URL to the full text of the article.
* '''access-date''' – Date the article was accessed online.


{{documentation}}
=== Example Usage ===
{{Cite journal
| title = Quantum entanglement in particle physics
| author = John Doe
| journal = Physics Today
| year = 2021
| volume = 72
| issue = 4
| pages = 15-20
| doi = 10.1234/phys.today.2021.123456
| pmid = 12345678
| url = https://example.com/full-text
| access-date = 2023-01-01
}}
</noinclude>
</noinclude>

Revision as of 16:58, 8 February 2025


Documentation

This template is used to cite journal articles. It dynamically formats citations based on the parameters provided.

Parameters

  • title – Title of the journal article (required).
  • author – Primary author(s).
  • first – First name(s) of the author(s).
  • last – Last name(s) of the author(s).
  • journal – Name of the journal.
  • year – Year of publication.
  • volume – Volume of the journal.
  • issue – Issue number of the journal.
  • pages – Page range of the article.
  • doi – DOI (Digital Object Identifier) of the article.
  • pmid – PubMed ID of the article.
  • pmc – PubMed Central ID of the article.
  • arxiv – arXiv identifier.
  • url – URL to the full text of the article.
  • access-date – Date the article was accessed online.

Example Usage

John Doe,

 Quantum entanglement in particle physics, 
 Physics Today, 
 2021,
 Vol. 72(Issue: 4),
 pp. 15-20,
 DOI: 10.1234/phys.today.2021.123456,
 PMID: 12345678,
 
 
 Full text,
 Accessed on: 2023-01-01.