Template:Quran ref: Difference between revisions
No edit summary |
No edit summary |
||
| (14 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<includeonly>{{#if:{{{chap|}}}|{{#if:{{{verses|}}}|[https://quran.com/{{{chap}}}/{{{verses}}} Quran {{{chap}}}:{{{verses}}}]|[https://quran.com/{{{chap}}} Quran {{{chap}}}]}}|Quran}}</includeonly> | <includeonly><span style="white-space:nowrap;display:inline;"> | ||
{{#if:{{{chap|}}}| | |||
{{#if:{{{verses|}}}| | |||
{{#if:{{#pos:{{{verses}}}|,}}| | |||
[https://quran.com/{{{chap}}}/{{#explode:{{#explode:{{{verses}}}|,|0}}|-|0}} Quran {{{chap}}}:{{{verses}}}] | |||
| | |||
[https://quran.com/{{{chap}}}/{{{verses}}} Quran {{{chap}}}:{{{verses}}}] | |||
}} | |||
| | |||
[https://quran.com/{{{chap}}} Quran {{{chap}}}] | |||
}} | |||
|Quran}} | |||
</span></includeonly><noinclude> | |||
The '''<nowiki>{{Quran ref}}</nowiki>''' template creates an external link to https://www.quran.com. | |||
< | '''Example input: <nowiki>{{Quran ref|chap=1|verses=1-2}}</nowiki>''' | ||
'''Example output:''' {{Quran ref|chap=1|verses=1-2}} | |||
</noinclude> | |||