Difference between revisions of "Template:Main-panel-with-icon"

From Wikispooks
Jump to navigation Jump to search
(objectClass2)
(Format as table)
Line 12: Line 12:
 
<nowiki>}}</nowiki>
 
<nowiki>}}</nowiki>
 
</noinclude><includeonly><includeonly>
 
</noinclude><includeonly><includeonly>
<div style="border-bottom:1px solid #9a9a9a; background-color:#d0e5f5; padding:0.5em 0.5em; font-size:112%;text-align:center;">'''{{#if: {{{link|}}}|[[{{{link}}}|{{{title|}}}]]|{{{title|}}}}}'''</div>
+
<div style="border-bottom:1px solid #9a9a9a; background-color:#d0e5f5; padding:0.5em 0.5em; font-size:112%;text-align:center;"></div>
 
<div style="padding:0.5em 0.5em 0.5em 0.5em;font-size:102%;">
 
<div style="padding:0.5em 0.5em 0.5em 0.5em;font-size:102%;">
 +
{|style="border-bottom:1px solid #9a9a9a; background-color:#d0e5f5; padding:0.5em 0.5em; font-size:112%;text-align:center;"
 +
|'''{{#if: {{{link|}}}|[[{{{link}}}|{{{title|}}}]]|{{{title|}}}}}'''
 +
|-
 
{{#if: {{{image|}}}|[[Image:{{{image}}}|link={{{link|}}}|alt={{{alt|}}}|right|65px]]}}
 
{{#if: {{{image|}}}|[[Image:{{{image}}}|link={{{link|}}}|alt={{{alt|}}}|right|65px]]}}
 
{{#Ask: {{{ask|}}}
 
{{#Ask: {{{ask|}}}
 
|sort={{#if: {{{sort|}}}|{{{sort|}}}|Creation date}}
 
|sort={{#if: {{{sort|}}}|{{{sort|}}}|Creation date}}
 
|order=descending
 
|order=descending
|?has objectClass2=
+
|?Has objectClass2=
 
|format=template
 
|format=template
 
|template=Main-panel-with-icon/output
 
|template=Main-panel-with-icon/output
 
|limit={{#if: {{{limit|}}}|{{{limit}}}|6}}
 
|limit={{#if: {{{limit|}}}|{{{limit}}}|6}}
 
}}
 
}}
 +
|}
 
</div>
 
</div>

Revision as of 08:23, 19 September 2014

This template makes a panel for the main page.

Usage:
{{Main-panel-with-icon
|ask= The SMW Query expression
|image= image for the section header
|alt= alt text for the image
|limit= how many results to show (defaults to 6)
|link= where to link the image and text
|title= section title
|sort= property to sort on (defaults to Creation date)
}}