Difference between revisions of "Template:Examples"

From Wikispooks
Jump to navigation Jump to search
(Better default for when keyProperties is not set)
({{FULLPAGENAME}} is superior to {{PAGENAME}})
 
Line 6: Line 6:
 
Plus a table of examples under this heading[[Category:Semantic Templates]]
 
Plus a table of examples under this heading[[Category:Semantic Templates]]
 
</noinclude><!-- The below test is to prevent re-displaying of data which will be displayed by {{JobHolders}}...
 
</noinclude><!-- The below test is to prevent re-displaying of data which will be displayed by {{JobHolders}}...
--><includeonly>{{#ifexpr: {{#ask: [[Has jobTitle::{{PAGENAME}}]]|format=count}}=0|{{SMWDocSection
+
--><includeonly>{{#ifexpr: {{#ask: [[Has jobTitle::{{FULLPAGENAME}}]]|format=count}}=0|{{SMWDocSection
|expression= [[Constitutes::{{PAGENAME}}]] OR [[Has posting::{{PAGENAME}}]]
+
|expression= [[Constitutes::{{FULLPAGENAME}}]] OR [[Has posting::{{FULLPAGENAME}}]]
 
|caption_singular=An example
 
|caption_singular=An example
 
|caption_plural=Examples
 
|caption_plural=Examples
 
|limit=200
 
|limit=200
 
|mainlabel = Page&nbsp;name
 
|mainlabel = Page&nbsp;name
|sort={{#show: {{PAGENAME}} | ?Has keySort}}
+
|sort={{#show: {{FULLPAGENAME}} | ?Has keySort}}
|properties={{#if: {{#show: {{PAGENAME}} | ?Has keyProperties}}|{{#show: {{PAGENAME}} | ?Has keyProperties}}|Description}}
+
|properties={{#if: {{#show: {{FULLPAGENAME}} | ?Has keyProperties}}|{{#show: {{FULLPAGENAME}} | ?Has keyProperties}}|Description}}
|headers={{#if: {{#show: {{PAGENAME}} | ?Has keyProperties}}|{{#show: {{PAGENAME}} | ?Has keyPropertyHeaders}}|Description}}}}}}</includeonly>
+
|headers={{#if: {{#show: {{FULLPAGENAME}} | ?Has keyProperties}}|{{#show: {{FULLPAGENAME}} | ?Has keyPropertyHeaders}}|Description}}}}}}</includeonly>

Latest revision as of 18:50, 3 February 2020

Bug1.jpg This template has problems: This is not displaying any results for Journalist. It should do. Use the discussion page to see the debate about this.

This template can be used on any pages which might have examples. It has no parameters.

If there are examples, it places a heading:

Example(s) on Wikispooks

Plus a table of examples under this heading