Template:Image: Difference between revisions

From The Reed and Rite
No edit summary
No edit summary
Line 7: Line 7:
-->]]</includeonly><noinclude>
-->]]</includeonly><noinclude>
== Image Usage Examples ==
== Image Usage Examples ==
{| style="width: 100%; text-align: left; margin: auto;" class="wikitable"
|-
! colspan="2" style="text-align: center;" | None
|-
! colspan="2" style="text-align: center;" |  Only the file name is passed.
|-
| width=50%|'''You Type'''
|'''You Get'''
|-
| width=50%|
<pre>{{Image|Pen.png}}</pre>
|
{{Image|Pen.png}}
|-
! colspan="2" style="text-align: center;" | None
|-
! colspan="2" style="text-align: center;" |  Only the file name is passed.
|-
| width=50%|'''You Type'''
|'''You Get'''
|-
| width=50%|
<pre>{{Image|Pen.png}}</pre>
|
{{Image|Pen.png}}
|}
{| style="width: 100%; text-align: left; margin: auto;" class="wikitable"
{| style="width: 100%; text-align: left; margin: auto;" class="wikitable"
|+ Usage Examples
|+ Usage Examples
|- class="title"
|- class="title"
! style="width: 5%;" | Parameter !! style="width: 10%;" | Description !! style="width: 40%;" | Code !! style="width: 40%;" | Example
! style="width: 10%;" | Parameter !! style="width: 10%;" | Description !! style="width: 30%;" | Code !! style="width: 50%;" | Example
|-
|-
| ''None'' || Only the file name is passed. || <pre>{{Image|Pen.png}}</pre> || {{Image|Pen.png}}
| ''None'' || Only the file name is passed. || <pre>{{Image|Pen.png}}</pre> || {{Image|Pen.png}}

Revision as of 22:33, 12 March 2025

Image Usage Examples

Usage Examples
Parameter Description Code Example
None Only the file name is passed.
{{Image|Pen.png}}
Caption File name and caption are passed.
{{Image|Pen.png|This is a caption}}
This is a caption
side=left Pushes the image over to the left, allowing text to flow around it.
{{Image|Pen.png|This is a caption|side=left}}
This is a caption
side=right Pushes the image over to the right, allowing text to flow around it.
{{Image|Pen.png|This is a caption|side=right}}
This is a caption
height=200px Sets the height of the image. If set, the width will adjust automatically to maintain aspect ratio.
{{Image|Pen.png|This is a caption|height=200px}}
This is a caption
width=200px Sets the width of the image. If set, the height will adjust automatically to maintain aspect ratio.
{{Image|Pen.png|This is a caption|width=200px}}
This is a caption
link=URL Makes the image clickable, linking it to a specific URL.
{{Image|Pen.png|Click here for more details|link=http://example.com}}
Click here for more details
artist=John Doe Specifies the artist's name for the image.
{{Image|Pen.png|This is a caption|artist=John Doe}}
by John Doe
This is a caption
Notes
The height parameter overrides the width parameter. To specify both width and height, pass width=WxHpx where W is the width and H is the height.