Template:Copy to Wikimedia Commons in/doc: Difference between revisions

Content deleted Content added
updated doc
 
Line 5:
 
<!-- Add categories where indicated at the bottom of this page and interwikis at Wikidata -->
== Usage ==
* <code><nowiki>{{Copy to Wikimedia Commons in|PUBLIC_DOMAIN_YEAR}}</nowiki></code>
 
The parameter PUBLIC_DOMAIN_YEAR is the year in which the media becomes public ___domain in the home country, and is mandatory.
{{tlx|copy to Wikimedia Commons in|public ___domain year}}
 
Whenever this template is transcluded, if the PUBLIC_DOMAIN_YEAR is in the future (for example: {{Tlx|Copy to Wikimedia Commons in|{{#time:Y|+2 years}}}}) then the template box will display the following:
<includeonly>{{sandbox other||
<div style="border-width:1px; border-style:dotted; border-color:grey;">
<!-- Categories below this line; interwikis at Wikidata -->
{{tlx|copyCopy to Wikimedia Commons in|public{{#time:Y|+2 ___domain yearyears}}|demo=y}}
[[Category:File message boxes|{{PAGENAME}}]]
</div>
[[Category:File namespace templates|{{PAGENAME}}]]
 
[[Category:Transwiki templates|{{PAGENAME}}]]
However, if the PUBLIC_DOMAIN_YEAR is in the past (for example: {{Tlx|Copy to Wikimedia Commons in|{{#time:Y|-2 years}}}}) then the template will display the following:
[[Category:Wikimedia Commons templates|{{PAGENAME}}]]
<div style="border-width:1px; border-style:dotted; border-color:grey;">
}}</includeonly>
{{Copy to Wikimedia Commons in|{{#time:Y|-2 years}}|demo=y}}
</div>
 
==TemplateData==
<templatedata>
{
Line 40 ⟶ 45:
}
</templatedata>
 
<includeonly>{{sandbox other||
<!-- Categories below this line; interwikis at Wikidata -->
[[Category:File message boxes|{{PAGENAME}}]]
[[Category:File namespace templates|{{PAGENAME}}]]
[[Category:Transwiki templates|{{PAGENAME}}]]
[[Category:Wikimedia Commons templates|{{PAGENAME}}]]
}}</includeonly>