More actions
(Created page with "<includeonly><span style="margin-left:0.5em;margin-right:0.5em;">{{#switch:{{{1|}}} |yt=link=http://youtube.com/watch?v={{{2|}}}<!-- -->{{#ifeq:{{...") |
m (add ability to define a custom link description) |
||
Line 1: | Line 1: | ||
<includeonly><span style="margin-left:0.5em;margin-right:0.5em;">{{#switch:{{{1|}}} | <includeonly><span style="margin-left:0.5em;margin-right:0.5em;">{{#switch:{{{1|}}} | ||
|yt=[[File:favicon-yt.png|link=http://youtube.com/watch?v={{{2|}}}]]<!-- | |yt=[[File:favicon-yt.png|link=http://youtube.com/watch?v={{{2|}}}]]<!-- | ||
--> | -->[http://youtube.com/watch?v={{{2|}}} {{{desc|{{#ifeq:{{{3|}}}|y|YouTube}}}}}] | ||
|nn=[[File:favicon-nn.png|link=http://www.nicovideo.jp/watch/{{{2|}}}]]<!-- | |nn=[[File:favicon-nn.png|link=http://www.nicovideo.jp/watch/{{{2|}}}]]<!-- | ||
--> | -->[http://www.nicovideo.jp/watch/{{{2|}}} {{{desc|{{#ifeq:{{{3|}}}|y|NicoNico}}}}}] | ||
|#default= | |#default= | ||
}}</span></includeonly><!-- | }}</span></includeonly><!-- | ||
Line 16: | Line 16: | ||
nn for NicoNico | nn for NicoNico | ||
| JUST the ID of the video (ie "so6700003") | | JUST the ID of the video (ie "so6700003") | ||
| y to display "YouTube" or "NicoNico" next to the icon | | y to display a default "YouTube" or "NicoNico" description next to the icon | ||
| desc = description (overrides "YouTube" or "NicoNico" default description) | |||
}} | }} | ||
{{Favicon|yt|jfwXGlwD1xg|y}}{{Favicon|nn|so6700003| | {{Favicon|yt|jfwXGlwD1xg|y}}{{Favicon|nn|so6700003|desc=NicoNico (JP)}} | ||
{{Favicon|yt|jfwXGlwD1xg}}{{Favicon|nn|so6700003}} | {{Favicon|yt|jfwXGlwD1xg}}{{Favicon|nn|so6700003}} | ||
</nowiki></pre> | </nowiki></pre> | ||
{{Favicon|yt|jfwXGlwD1xg|y}}{{Favicon|nn|so6700003| | {{Favicon|yt|jfwXGlwD1xg|y}}{{Favicon|nn|so6700003|desc=NicoNico (JP)}} | ||
{{Favicon|yt|jfwXGlwD1xg}}{{Favicon|nn|so6700003}} | {{Favicon|yt|jfwXGlwD1xg}}{{Favicon|nn|so6700003}} | ||
[[Category:Templates]] | [[Category:Templates]] | ||
</noinclude> | </noinclude> |
Revision as of 02:44, 23 March 2019
This template displays a favicon for NicoNico or YouTube plus a link to the video.
Usage
{{Favicon | yt for Youtube nn for NicoNico | JUST the ID of the video (ie "so6700003") | y to display a default "YouTube" or "NicoNico" description next to the icon | desc = description (overrides "YouTube" or "NicoNico" default description) }} {{Favicon|yt|jfwXGlwD1xg|y}}{{Favicon|nn|so6700003|desc=NicoNico (JP)}} {{Favicon|yt|jfwXGlwD1xg}}{{Favicon|nn|so6700003}}