Open main menu

The Aruba Wiki β

Changes

Template:ImageDiv

1,483 bytes added, 00:45, 15 August 2018
no edit summary
<includeonly>{{#switch: {{{type|}}}|0=<div style="background-color:{{{bgcolor|black}}}; border-radius: 5px; padding: 3px; width: {{{img-width|155px}}}; position: relative;"><div style="border-radius: 2px; overflow: hidden; width: {{{img-width|155px}}}; height: {{{img-height|125px}}};">{{{image|}}}</div>{{#if: {{{name|}}} |<span style="background-color:{{{namebgcolor|black}}}; position: absolute; {{{direction|right}}}: 0px; bottom: 0px; font-size: {{{fontsize|x-small}}}; font-weight: bold; color: {{{namecolor|white}}}; padding: {{{padding|0 5px}}}; border-radius: {{{border-radius|5px 0}}};">{{{name|}}}</span> }}</div>|1=<div style="background-color:{{{bgcolor|black}}}; border-radius: 5px; padding: 3px; width: {{{img-width|155px}}}; position: relative;"><div style="border-radius: 2px; overflow: hidden; width: {{{img-width|155px}}}; height: {{{img-height|125px}}};">{{PlainURL|1={{{articlename|}}}|2={{{image|}}}}}</div>{{#if: {{{name|}}} |[[{{{articlename|}}}|<span style="background-color:{{{namebgcolor|black}}}; position: absolute; right: 0px; bottom: 0px; font-size: {{{fontsize|x-small}}}; font-weight: bold; color: {{{namecolor|white}}}; padding: 0 5px; border-radius: 5px 0;">{{{name|}}}</span>]]}}</div>|2=<div style="background-color:{{{bgcolor|black}}}; border-radius: 5px; padding: 3px; width: {{{img-width|155px}}}; position: relative;"><div style="border-radius: 2px; overflow: hidden; width: {{{img-width|155px}}}; height: {{{img-height|125px}}};">{{{image|}}}</div>{{#if: {{{name|}}} |[[{{{articlename|}}}|<span style="background-color:{{{namebgcolor|black}}}; position: absolute; right: 0px; bottom: 0px; font-size: {{{fontsize|x-small}}}; font-weight: bold; color: {{{namecolor|white}}}; padding: 0 5px; border-radius: 5px 0;">{{{name|}}}</span>]] }}</div>}} </includeonly>
<noinclude>
{{ImageDiv
| articlename type = :Category:Hotels0
| name = Hotels
| image = [[File:Placeholder.jpg|155px]]
<pre>
{{ImageDiv
| articlename type = :Category:Hotels0
| name = Hotels
| image = [[File:Placeholder.jpg|155px]]
| bgcolor = orange
| namebgcolor = orange
====Usage====
{{ImageDiv
| articlename type =
| name =
| image =
====Usage====
*'''''articlenametype''''' – The name of the article Switch between allow links (in this case1) or no (0), [[Hotels]](2). This will also be the article which will open once the user clicks on the title or image.allow to use &lt;img&gt; tag
*'''''name''''' – Display name (ie., the name you want the template to display)
*'''''image''''' – File name
*'''''img-height''''' – Set div height (default to 125px).
*'''''img-size''''' – Set image size (default to 155px).
*'''''direction''''' – Direction of the Text (default to right).*'''''border-radius''''' – Set border-radius of the text area (default to 5px 0).*'''''border-radius''''' – Set padding of the text area (default to 0 5px).*'''''namecolor''''' – Set text color of text area (default to white).
[[Category:Templates]]</noinclude>