Template:Author: Difference between revisions

From ChoralWiki
Jump to navigation Jump to search
No edit summary
No edit summary
(7 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>{{#switch:{{ucfirst: {{{1|Error}}} }}
<includeonly>{{#if:{{{an3|}}}|{{#ifexist:{{alias|{{{an3}}}}}|{{#dplvar:set|ax3|[[{{alias|{{{an3}}}}}|{{{an3}}}]]}}|{{#dplvar:set|ax3|{{{an3}}}<sup>[{{fullurl:{{alias|{{{an3}}}}}|action=edit&preload=Template:New_lyricist/Preload}} create page]</sup>}}}}}}{{#if:{{{an2|}}}|{{#ifexist:{{alias|{{{an2}}}}}|{{#dplvar:set|ax2|[[{{alias|{{{an2}}}}}|{{{an2}}}]]}}|{{#dplvar:set|ax2|{{{an2}}}<sup>[{{fullurl:{{alias|{{{an2}}}}}|action=edit&preload=Template:New_lyricist/Preload}} create page]</sup>}}}}}}{{#if:{{{1|}}}|{{#switch:{{{1|}}}|Anonymous|Anonymous author|Traditional|Unknown={{#dplvar:set|an1|Anonymous}}[[Category:Anonymous texts]]|#default={{#dplvar:set|ax1|[[{{{1|}}}]]}}[[Category:Texts by known authors]]}}|{{#dplvar:set|ax1|}}}}{{#switch:{{{page|text}}}|work=:({{#if:{{{an3|}}}|{{#dplvar:ax1}}, {{#dplvar:ax2}}, and {{#dplvar:ax3}}|{{#if:{{{an2|}}}|{{#dplvar:ax1}} and {{#dplvar:ax2}}|{{#dplvar:ax1}}}}}}{{#if:{{{yr|}}}|, {{{yr|}}}}})|text={{#if:{{{an3|}}}|<b>Authors:</b> {{#dplvar:ax1}}, {{#dplvar:ax2}}, and {{#dplvar:ax3}}|{{#if:{{{an2|}}}|<b>Authors:</b> {{#dplvar:ax1}} and {{#dplvar:ax2}}|<b>Author:</b> {{#dplvar:ax1}}}}}}{{#if:{{{yr|}}}|, {{{yr|}}}}}{{#if:{{{pub|}}}|&nbsp;in ''{{{pub}}}''}}.}}</includeonly><noinclude>
|Error ='''Error:''' <font color="red">''Please use the syntax'' {{tl|Author|''Author name''}}</font>
| ='''Author:'''
|2 ='''Authors:''' {{#ifexist:{{alias|{{{2}}}}}|[[{{alias|{{{2}}}}}|{{{2}}}]]|{{{2}}}<small><sup>[{{fullurl:{{alias|{{{2}}}}}|action=edit&preload=Template:New_lyricist/Preload}} create page]</sup></small>[[Category:Texts with nonexistent author page]]}}{{#if:{{{5|}}}|{{{4|}}}}}{{{connective|&nbsp;and}}} {{#ifexist:{{alias|{{{3}}}}}|[[{{alias|{{{3}}}}}|{{{3}}}]]|{{{3}}}<small><sup>[{{fullurl:{{alias|{{{3}}}}}|action=edit&preload=Template:New_lyricist/Preload}} create page]</sup></small>[[Category:Texts with nonexistent author page]]}}{{{5|{{{4|}}}}}} <span style="display:none">[[{{alias|{{{2}}}}} settings| ]][[{{alias|{{{3}}}}} settings| ]]{{#dplvar:set|lyn1|{{{2|}}}}}{{#dplvar:set|lyn2|{{{3|}}}}}</span>{{IfMain|[[Category:Texts by known authors]]}}
|3 ='''Authors:''' [[{{alias|{{{2}}}}}|{{{2}}}]]{{#if:{{{6|}}}|{{{5|}}}}}, [[{{alias|{{{3}}}}}|{{{3}}}]]{{{6|}}} and [[{{alias|{{{4}}}}}|{{{4}}}]]{{{7|{{#if:{{{6|}}}||{{{5|}}}}}}}} <span style="display:none">[[{{alias|{{{2}}}}} settings| ]][[{{alias|{{{3}}}}} settings| ]][[{{alias|{{{4}}}}} settings| ]]{{#dplvar:set|lyn1|{{{2|}}}}}{{#dplvar:set|lyn2|{{{3|}}}}}{{#dplvar:set|lyn3|{{{4|}}}}}</span>{{IfMain|[[Category:Texts by known authors]]}}
|Anonymous
|Anonymous lyricist
|Traditional
|Unknown ='''Author:''' [[Anonymous lyricist|{{ucfirst: {{{1}}} }}]]{{{2|}}} <span style="display:none">[[Anonymous lyricist settings| ]]{{#dplvar:set|lyn1|Anonymous}}</span>{{IfMain|[[Category:Texts by unknown authors]]}}
|#default='''Author:''' {{#ifexist:{{alias|{{{1}}}}}|[[{{alias|{{{1}}}}}|{{{1}}}]]|{{{1}}}<small><sup>[{{fullurl:{{alias|{{{1}}}}}|action=edit&preload=Template:New_lyricist/Preload}} create page]</sup></small>[[Category:Texts with nonexistent author page]]}}{{{2|}}} <span style="display:none">[[{{alias|{{{1}}}}} settings| ]]{{#dplvar:set|lyn1|{{{1|}}}}}</span>{{IfMain|[[Category:Texts by known authors]]}}
}}</includeonly><noinclude>
{{prot-temp}}
{{prot-temp}}
{{Doc|1=
{{Doc|1=
'''This template''' is designed for a '''text page''', so that the a link to the text can appear on the author's "Lyricist" page, using template {{tl|AuthorTextsList}}. Template <tt>Author</tt> should not be used on a ''work'' page, where template <tt>Lyricist</tt> is appropriate.
'''This template''' is designed for a '''text page''', so that the a link to the text can appear on the author's "Lyricist" page, using template {{tl|AuthorTextsList}}. Template <tt>Author</tt> may also be used on a ''work'' page, below the text.
;Syntax for one Author
*{{tl|Author|''Author_name''|''optional_text''}}
:which produces the text
::'''Author:''' <font color=blue>Author_name</font> optional_text


;Syntax for two Authors
;Syntax
*{{tl|Author|2|''Author1_name''|''Author2_name''|''optional_text''}}
<tt><nowiki>{{Author|<Author>|<First text line>|yr=<year>|page=<text or work>|an2=<aname2>|an3=<aname3>|pub=<pubname>}}</nowiki></tt>
:which produces the text
::'''Authors:''' <font color=blue>Author1_name</font> and <font color=blue>Author2_name</font> optional_text


The conjunction "and" may be replaced by inserting another parameter:
<u>Parameters</u>
*{{tl|Author|2|''Johann Gottfried Herder''|connective{{=}}'', after''|''Ossian''}}
# Author's name, exactly as it appears on the Author (Lyricist) page.
:produces the text
# First line of <u>text</u>, same as a text page title (without the author's name) but not necessarily the work page title. This text will appear on the Author-Lyricist's page under <big>Texts by (Author)</big>.
::'''Authors:''' <font color=blue>Johann Gottfried Herder</font>, after <font color=blue>Ossian</font>
* <tt>yr=</tt> – Year the text was published.
* <tt>page=</tt> – One of three words: (a) <tt>text</tt> for use as a separate line on a text page, ''or'' (b) <tt>work</tt> for use following text on a work page, ''or'' (c) <tt>line</tt> for use within a text line on a work page or text page. Defaults to <tt>text</tt>
* <tt>an2=</tt> – (Optional) second author.
* <tt>an3=</tt> – (Optional) third author.
* <tt>pub=</tt> – (Optional) title of publication where text first appeared. If you want a link to appear, you must supply square brackets; please do not use either template {{tl|NoCo}} or {{tl|NoComp}} – the curly brackets will mess up the program.


;Syntax for three Authors
<u>Appearance of template</u>
*{{tl|Author|3|''Author1_name''|''Author2_name''|''Author3_name''|''optional_text''}}
{{{!}}class="wikitable" align=center
:which produces the text
!color=#ddffdd{{!}}Command
::'''Authors:''' <font color=blue>Author1_name</font>, <font color=blue>Author2_name</font> and <font color=blue>Author3_name</font> optional_text
!color=#ddffdd{{!}}page=
!color=#ddffdd{{!}}Appearance
!color=#ddffdd{{!}}Use on pagetype:
{{!}}-
{{!}}rowspan=4{{!}}<nowiki>{{Author|Paul Gerhardt|Befiehl du deine Wege|yr=1653|page=…}}</nowiki>{{!}}{{!}}text{{!}}{{!}}'''Author:''' <font color=blue>Paul Gerhardt</font>, 1664{{!}}{{!}}Text page
{{!}}-
{{!}}work{{!}}{{!}}(<font color=blue>Paul Gerhardt</font>, 1664){{!}}{{!}}Work page, below text
{{!}}-
{{!}}line{{!}}{{!}}……<font color=blue>Paul Gerhardt</font> (1664)……{{!}}{{!}}Either Work or Text page
{{!}}-
{{!}}}


;Categorization
;Categorization
Whenever this template is used, the page is included in category {{CiteCat|Texts by known authors}}
Whenever this template is used, the page is included in category {{CiteCat|Texts by known authors}}


}}
;Also see
*Template {{tl|Lyricist}}
*Template {{tl|AuthorTextsList}}
*Template {{tl|LyricistSettingsList}}
 
Version 3 – 2020-11-19}}


[[Category:Templates]]</noinclude>
[[Category:Templates]]</noinclude>

Revision as of 03:22, 22 February 2021

Documentation

This template is designed for a text page, so that the a link to the text can appear on the author's "Lyricist" page, using template {{AuthorTextsList}}. Template Author may also be used on a work page, below the text.

Syntax

{{Author|<Author>|<First text line>|yr=<year>|page=<text or work>|an2=<aname2>|an3=<aname3>|pub=<pubname>}}

Parameters

  1. Author's name, exactly as it appears on the Author (Lyricist) page.
  2. First line of text, same as a text page title (without the author's name) but not necessarily the work page title. This text will appear on the Author-Lyricist's page under Texts by (Author).
  • yr= – Year the text was published.
  • page= – One of three words: (a) text for use as a separate line on a text page, or (b) work for use following text on a work page, or (c) line for use within a text line on a work page or text page. Defaults to text
  • an2= – (Optional) second author.
  • an3= – (Optional) third author.
  • pub= – (Optional) title of publication where text first appeared. If you want a link to appear, you must supply square brackets; please do not use either template {{NoCo}} or {{NoComp}} – the curly brackets will mess up the program.

Appearance of template

Command page= Appearance Use on pagetype:
{{Author|Paul Gerhardt|Befiehl du deine Wege|yr=1653|page=…}} text Author: Paul Gerhardt, 1664 Text page
work (Paul Gerhardt, 1664) Work page, below text
line ……Paul Gerhardt (1664)…… Either Work or Text page
Categorization

Whenever this template is used, the page is included in category Texts by known authors

Also see

Version 3 – 2020-11-19