Difference between revisions of "Template:Image"
Jump to navigation
Jump to search
sc4e>Jdenm8 (Editing so that internal links are referred using [[]] instead of a full URL.) |
sc4e>Jdenm8 |
||
Line 1: | Line 1: | ||
− | <noinclude> | + | <noinclude>{{pp-template}}</noinclude><noinclude>This template includes an external image, and can also link you to either the external image, an internal article or an external link. |
− | {{pp-template}} | + | ==Syntax== |
− | </ | + | <nowiki>{{img |
+ | | 1 | ||
+ | | page | ||
+ | | url | ||
+ | | width | ||
+ | }}</nowiki> | ||
+ | *'''1''': The external image URL | ||
+ | *'''''page''''': An article name | ||
+ | *'''''url''''': An external URL to link to | ||
+ | *'''''width''''': can take these values | ||
+ | **tinyImg: upto 300px | ||
+ | **smallImg: upto 500px | ||
+ | **all others are 800px | ||
− | < | + | ==Example== |
+ | </noinclude><span class="plainlinks" {{#if:{{{width|}}}|id="{{{width}}}"}}>{{#if:{{{page|}}}{{{url|}}}|<!-- page or url parameters set | ||
− | + | -->{{#if:{{{page|}}}|<!-- | |
− | + | page parameter set -->[{{fullurl:{{{page}}}}} {{{1}}}]|<!-- | |
− | {{#if: | + | url parameter set -->[{{{url}}} {{{1}}}]}}<!-- |
− | + | neither set -->|{{{1}}}}}</span><noinclude> | |
− | <!-- page | + | *Where neither is set: |
− | + | {{img|http://www.sc4devotion.com/img/SC4DVD_1.jpg}} | |
− | + | *Where page is set (to [[Main Page]]): | |
− | + | {{img|http://www.sc4devotion.com/img/SC4DVD_1.jpg|page=Main_Page}} | |
− | + | *Where url is set (too google): | |
− | + | {{img|http://www.sc4devotion.com/img/SC4DVD_1.jpg|url=http://www.google.com/}} | |
− | <!-- neither set --> | + | *Where width is set (to tinyImg): |
− | + | {{img|http://www.sc4devotion.com/img/SC4DVD_1.jpg|width=tinyImg}} | |
− | </ | ||
− | |||
− | <noinclude> | ||
− | {{ | ||
− |
Revision as of 22:03, 17 November 2012
This high-risk template has been protected from editing to prevent vandalism. See the protection policy and protection log for more details. Please discuss any changes on the talk page; you may ask an editor or a moderator to make the edit if it is supported by consensus. You may also request that this page be unprotected. |
This template includes an external image, and can also link you to either the external image, an internal article or an external link.
Syntax
{{img | 1 | page | url | width }}
- 1: The external image URL
- page: An article name
- url: An external URL to link to
- width: can take these values
- tinyImg: upto 300px
- smallImg: upto 500px
- all others are 800px
Example
{{{1}}}
- Where neither is set:
http://www.sc4devotion.com/img/SC4DVD_1.jpg
- Where page is set (to Main Page):
http://www.sc4devotion.com/img/SC4DVD_1.jpg
- Where url is set (too google):
http://www.sc4devotion.com/img/SC4DVD_1.jpg
- Where width is set (to tinyImg):