Template:Cite Quran: Difference between revisions
From Zoophilia Wiki
Jump to navigationJump to search
meta>Tarikash placing the "]" inside the prev switch, and adding the value "r" alternative to "ref" |
meta>Tarikash adding one more parameter "tn" to allow specifying translator's name only, without the beginning "Translated by" words |
||
Line 1: | Line 1: | ||
<includeonly>{{ | <includeonly>{{ | ||
#ifeq: {{lc: {{{style|{{{s|sup}}}}}} }} | #ifeq:{{lc:{{{style|{{{s|sup}}}}}} }} | ||
| sup | | sup | ||
| {{#if: {{{quote|{{{q|}}}}}} | “{{{quote|{{{q|}}}}}}” }}<sup><nowiki>[</nowiki> | |{{#if:{{{quote|{{{q|}}}}}} | “{{{quote|{{{q|}}}}}}” }}<sup><nowiki>[</nowiki> | ||
}}{{ | }}{{ | ||
#switch: {{lc: {{{expand|{{{begin|{{{b|yes}}}}}}}}} }} | #switch:{{lc:{{{expand|{{{begin|{{{b|yes}}}}}}}}} }} | ||
| | | y | ||
| | | yes=[[Qur'an]] | ||
| no= | | no= | ||
| n= | | n= | ||
| #default={{# | | #default={{ | ||
#switch:{{lc:{{{style|{{{s|sup}}}}}} }} | |||
| ref | |||
| r=[[Qur'an]] | |||
}} | |||
}}[{{ | }}[{{ | ||
#if: {{{2|}}} | #if:{{{2|}}} | ||
| | |http://www.usc.edu/dept/MSA/quran/{{padleft:{{{1}}}|3|0}}.qmt.html#{{padleft:{{{1}}}|3|0}}.{{padleft:{{{2|ERROR}}}|3|0}} {{{1}}}:{{{2|ERROR}}} | ||
}}{{ | }}{{ | ||
#if: {{{end|{{{e|}}}}}} | #if:{{{end|{{{e|}}}}}} | ||
|-{{{end|{{{e|}}}}}} | | -{{{end|{{{e|}}}}}} | ||
}}]{{ | }}]{{ | ||
#switch: {{lc: {{{style|{{{s|sup}}}}}} }} | #switch:{{lc:{{{style|{{{s|sup}}}}}} }} | ||
| nosup | | nosup | ||
| ns | | ns | ||
| r | | r | ||
| ref={{#if: {{{translator|{{{t|}}}}}} | <sup>([[Qur'an translations|Translated]] by }} | | ref={{ | ||
| #default={{#if: {{{translator|{{{t|}}}}}} | ( }} | #if:{{{translator|{{{t|}}}}}} | ||
|{{#if:{{{tn|}}}| <sup>( | <sup>([[Qur'an translations|Translated]] by }} | |||
|{{#if:{{{tn|}}}| <sup>( }} | |||
}} | |||
| #default={{#if:{{{translator|{{{t|}}}}}} | ([[Qur'an translations|Translated]] by | {{#if:{{{tn|}}}| ( }} }} | |||
}}{{ | }}{{ | ||
#if: {{{translator|{{{t|}}}}}} | #if:{{{translator|{{{t|}}}}}} | ||
| {{ #switch: {{lc: {{{translator|{{{t|}}}}}} }} | |{{#switch:{{lc:{{{translator|{{{t|}}}}}} }} | ||
| y=[[Abdullah Yusuf Ali|Yusuf Ali]] | | y=[[Abdullah Yusuf Ali|Yusuf Ali]] | ||
| p=[[Marmaduke Pickthall|Pickthall]] | | p=[[Marmaduke Pickthall|Pickthall]] | ||
Line 37: | Line 39: | ||
| a=[[Muhammad Asad|Asad]] | | a=[[Muhammad Asad|Asad]] | ||
| #default={{{translator|{{{t|}}}}}} | | #default={{{translator|{{{t|}}}}}} | ||
}} | }} | ||
|{{ | |||
#if:{{{tn|}}} | |||
|{{#switch:{{lc:{{{tn|}}} }} | |||
| y=[[Abdullah Yusuf Ali|Yusuf Ali]] | |||
| p=[[Marmaduke Pickthall|Pickthall]] | |||
| s=[[Mohammed Habib Shakir|Shakir]] | |||
| a=[[Muhammad Asad|Asad]] | |||
| #default={{{tn|}}} | |||
}} | |||
}} | |||
}}{{ | }}{{ | ||
#if: {{{translator|{{{t|}}}}}} | #if:{{{translator|{{{t|}}}}}} | ||
| ) | | ) | ||
| {{ | |||
#if:{{{tn|}}} | |||
| ) | |||
}} | |||
}}{{ | }}{{ | ||
#switch: {{lc: {{{style|{{{s|sup}}}}}} }} | #switch:{{lc:{{{style|{{{s|sup}}}}}} }} | ||
| nosup | | nosup | ||
| ns | | ns | ||
| r | | r | ||
| ref={{#if: {{{translator|{{{t|}}}}}} | </sup> }} | | ref={{#if:{{{translator|{{{t|}}}}}} | </sup> | {{#if:{{{tn|}}}|</sup> }} }} | ||
}}{{ | }}{{ | ||
#ifeq: {{lc: {{{style|{{{s|sup}}}}}} }} | #ifeq:{{lc:{{{style|{{{s|sup}}}}}} }} | ||
| sup | | sup | ||
| <nowiki>]</nowiki></sup> | | <nowiki>]</nowiki></sup> | ||
| {{#if: {{{quote|{{{q|}}}}}} | . “{{{quote|{{{q|ERROR: Quote Missing}}}}}}” }} | | {{#if:{{{quote|{{{q|}}}}}} | . “{{{quote|{{{q|ERROR: Quote Missing}}}}}}” }} | ||
}}</includeonly><noinclude> | }}</includeonly><noinclude> | ||
{{esoteric}} | {{esoteric}} | ||
==Usage== | ==Usage== | ||
<pre> | <pre> | ||
{{ | {{Cite quran|#1|#2 | ||
| end= | | end= (e=) | ||
| translator= | | translator= (t=) | ||
| style= | | tn= | ||
| expand= | | style= (s=) | ||
| quote= | | expand= (begin= , b=) | ||
| quote= (q=) | |||
}} | }} | ||
</pre> | </pre> | ||
Line 72: | Line 89: | ||
==Optional Parameters== | ==Optional Parameters== | ||
* '''end''' or '''e''' parameter ''':''' | * '''end''', or, '''e''' parameter ''':''' | ||
:* last ayah number being cited | :* last ayah number being cited | ||
* '''quote''' or '''q''' ''':''' | * '''quote''', or, '''q''' ''':''' | ||
:* the text of the quotation | :* the text of the quotation | ||
* '''translator''' or '''t''' parameter can have below values ''':''' | * '''translator''', or, '''t''' parameter can have below values ''':''' | ||
:* '''y''' ( | :* '''y''' for ([[Qur'an translations|Translated]] by [[Abdullah Yusuf Ali|Yusuf Ali]]) | ||
:* '''p''' ( | :* '''p''' for ([[Qur'an translations|Translated]] by [[Marmaduke Pickthall|Pickthall]]) | ||
:* '''s''' ( | :* '''s''' for ([[Qur'an translations|Translated]] by [[Mohammed Habib Shakir|Shakir]]) | ||
:* '''a''' ( | :* '''a''' for ([[Qur'an translations|Translated]] by [[Muhammad Asad|Asad]]) | ||
:* name of other translator | :* name of other translator | ||
* '''expand=no''' or '''begin=no''' or '''b=no''' or '''b=n''' ''':''' | * '''tn''' (translator name only) parameter can have below same values ''':''' | ||
:* '''y''' for ([[Abdullah Yusuf Ali|Yusuf Ali]]) | |||
:* '''p''' for ([[Marmaduke Pickthall|Pickthall]]) | |||
:* '''s''' for ([[Mohammed Habib Shakir|Shakir]]) | |||
:* '''a''' for ([[Muhammad Asad|Asad]]) | |||
:* name of other translator | |||
* '''expand=no''', or, '''begin=no''', or, '''b=no''', or, '''b=n''' ''':''' | |||
:* does not prepend link with "[[Qur'an]]", alternatively begin=no, b=no can also be used. Instead of "no", "n" can also be used. | :* does not prepend link with "[[Qur'an]]", alternatively begin=no, b=no can also be used. Instead of "no", "n" can also be used. | ||
* '''style''' or '''s''' parameter can have below values ''':''' | * '''style''', or, '''s''' parameter can have below values ''':''' | ||
:* '''nosup''' or '''ns''' to use non-superscript style. | :* '''nosup''', or, '''ns''' to use non-superscript style. | ||
:* '''ref''' or '''r''' to use expanded form for citing as a reference (short form for | :* '''ref''', or, '''r''' to use expanded form for citing as a reference (short form for <i>style=nosup|expand=yes</i>). | ||
See [[Template_talk:Cite quran|Talk/Discussion]] page for further details. | '''See''' [[Template_talk:Cite quran|'''Talk/Discussion''']] page for further details, examples, discussion, etc. | ||
[[Category:Specific source templates|Quran]] | [[Category:Specific source templates|Quran]] |
Revision as of 04:28, 23 January 2008
Usage
{{Cite quran|#1|#2 | end= (e=) | translator= (t=) | tn= | style= (s=) | expand= (begin= , b=) | quote= (q=) }}
Required Parameters
- #1
- integer representing the number of the surah (this must be the first parameter).
- #2
- integer representing the ayah number (this must be the second parameter).
Optional Parameters
- end, or, e parameter :
- last ayah number being cited
- quote, or, q :
- the text of the quotation
- translator, or, t parameter can have below values :
- y for (Translated by Yusuf Ali)
- p for (Translated by Pickthall)
- s for (Translated by Shakir)
- a for (Translated by Asad)
- name of other translator
- tn (translator name only) parameter can have below same values :
- expand=no, or, begin=no, or, b=no, or, b=n :
- does not prepend link with "Qur'an", alternatively begin=no, b=no can also be used. Instead of "no", "n" can also be used.
- style, or, s parameter can have below values :
- nosup, or, ns to use non-superscript style.
- ref, or, r to use expanded form for citing as a reference (short form for style=nosup|expand=yes).
See Talk/Discussion page for further details, examples, discussion, etc.