Jump to content

User:Begoon/POTD custom and User:Begoon/POTD custom/sandbox: Difference between pages

(Difference between pages)
Page 1
Page 2
Content deleted Content added
Fix Linter errors.
 
sync to main
 
Line 1: Line 1:
<noinclude>__NOTOC__
<noinclude>
== POTD custom ==
{{User:Begoon/POTD custom|sTwidth=400}}{{-}}</noinclude><includeonly><div align="center" style="width:{{{sTwidth|500}}}px; border:0;"><div class="thumb" style="margin-bottom:1em;"><div class=thumbinner style="padding-top:12px !important;padding-bottom:12px !important;padding:1px; border:{{{borderWidth|1}}}px {{{borderColour|silver}}} solid; background-color:white;">[[Wikipedia:Picture_of_the_day|<span style="opacity:{{{textOpacity|1.0}}}; font-size:150%; color:{{{textColour|darkSlateBlue}}} !important;">Picture of the day</span>]] <span style="font-size:90%; font-style: oblique; opacity:{{{textOpacity|1.0}}}; color:{{{textColour|darkSlateBlue}}} !important;">&nbsp;(from {{{whichYear|{{User:Begoon/Random year for FP}}}}})<br /></span>{{#ifeq:{{{thumb}}}|yes|<div class="thumb"><div class=thumbinner style="padding: 1px;">{{#ifeq:{{{title}}}|yes|[[Wikipedia:Picture_of_the_day|Wikipedia Picture of the Day]]<br />|}}||}}[[Image:{{#if:||{{POTD/{{{whichYear|{{User:Begoon/Random year for FP}}}}}{{#time:-m-d}}|image}}}}|{{#expr: ( {{{sTwidth|500}}} ) - 20 }}x{{#expr: (( {{{sTwidth|500}}} ) * 0.66667) round0 }}px]]<span style="opacity:{{{textOpacity|1.0}}}; text-align:center;font-size:120%;color:{{{textColour|darkSlateBlue}}} !important;width:{{#expr: ( {{{sTwidth|500}}} ) - 20 }}px;display:block;margin-top:4px;">{{{caption|{{POTD/{{{whichYear|{{User:Begoon/Random year for FP}}}}}{{#time:-m-d}}|title}}}}}</span></div></div></div></includeonly><noinclude>
{{User:Begoon/POTD custom|sTwidth=400}}{{clear}}
'''This is a customised Picture of the day template, the year may be specified.'''
* It displays the POTD, with caption, automatically, in a box with a border.
* The picture is the POTD for today's date, the year selected between 2008 and the current year ({{CURRENTYEAR}}) (or at random).
* The image height is limited by a calculation based on width, to prevent excess depth in some portrait images.<br /></noinclude><includeonly><div align="center" style="width:{{{sTwidth|500}}}px; border:0px solid red;"><div class="thumb" style="margin-bottom:1em;"><div class=thumbinner style="padding-top:12px !important;padding-bottom:12px !important;padding:1px; border:{{{borderWidth|1}}}px {{{borderColour|silver}}} solid; background-color:white;">[[Wikipedia:Picture_of_the_day|<font style="opacity:{{{textOpacity|1.0}}}; font-size:150%; color:{{{textColour|darkSlateBlue}}} !important;">Picture of the day]] <small style="opacity:{{{textOpacity|1.0}}}; color:{{{textColour|darkSlateBlue}}} !important;">&nbsp;(from {{{whichYear|{{User:Begoon/Random year for FP}}}}})<br /></small></font>{{#ifeq:{{{thumb}}}|yes|<div class="thumb"><div class=thumbinner style="padding: 1px;">{{#ifeq:{{{title}}}|yes|[[Wikipedia:Picture_of_the_day|Wikipedia Picture of the Day]]<br />|}}||}}[[Image:{{#if:||{{POTD/{{{whichYear|{{User:Begoon/Random year for FP}}}}}{{#time:-m-d}}|image}}}}|{{#expr: ( {{{sTwidth|500}}} ) - 20 }}x{{#expr: (( {{{sTwidth|500}}} ) * 0.66667) round0 }}px]]<font style="opacity:{{{textOpacity|1.0}}}; text-align:center;font-size:120%;color:{{{textColour|darkSlateBlue}}} !important;width:{{#expr: ( {{{sTwidth|500}}} ) - 20 }}px;display:block;margin-top:4px;">{{{caption|{{POTD/{{{whichYear|{{User:Begoon/Random year for FP}}}}}{{#time:-m-d}}|title}}}}}</font></div></div></div></div></div></includeonly><noinclude>
{{Documentation}}</noinclude>
{{Documentation}}</noinclude>