Difference between revisions of "Template:SMWData"

From Wikispooks
Jump to navigation Jump to search
(Make description visible)
(Make description visible)
Line 1: Line 1:
 
<noinclude>[[category:Semantic Templates]]
 
<noinclude>[[category:Semantic Templates]]
'''This template is for adding SMW data where no main template is in use. It should ''not'' be used when a template is already in use that adds SMW data.<br/>
+
'''This template is for adding SMW data where no main template is in use. It should be used at the ''top'' of the page. It should ''not'' be used when a template is already in use that adds SMW data.<br/>
 
(So, not for {{temp|website}}s, {{temp|document}}s, {{temp|event}}s, files or {{temp|person}}s)'''<br/>
 
(So, not for {{temp|website}}s, {{temp|document}}s, {{temp|event}}s, files or {{temp|person}}s)'''<br/>
''It doesn't produce any visual output'' - it only adds semantic data to the document. As such, it can be placed anywhere in the document, however it is good practice to use it at the top.
+
''The only parameter displayed is the 'description'.'' - All the other parameters contribute only to the document's semantic mark up.
 
{{BLUE|The blue parameters not be marked up at all; they should be Wikispooks page names (whether or not the page yet exists).}}<br/>
 
{{BLUE|The blue parameters not be marked up at all; they should be Wikispooks page names (whether or not the page yet exists).}}<br/>
 
{{GREEN|The green parameters should be /-separated lists.}}<br/>
 
{{GREEN|The green parameters should be /-separated lists.}}<br/>
Line 22: Line 22:
 
}}
 
}}
 
</poem>
 
</poem>
</noinclude><includeonly>{{#if: {{{Description|}}} | {{Description|[[Description::{{{Description}}}| ]]}}}}{{#if: {{{KeyProperties|}}}|[[Has key properties::{{{KeyProperties}}}| ]]}}{{#if: {{{KeyPropertyHeaders|}}}|[[Has key property headers::{{{KeyPropertyHeaders}}}| ]]}}{{#if: {{{ON_constitutes|}}}    | [[ON_constitutes::{{{ON_constitutes}}}| ]]}}{{#if: {{{ON_cause|}}}    | [[ON_has_cause::{{{ON_cause}}}| ]]}}{{#if: {{{Constitutes|}}}    | [[Constitutes::{{{Constitutes}}}| ]]}}{{#if: {{{Constitutes2|}}}    | [[Constitutes::{{{Constitutes2}}}| ]]}}{{#if: {{{Constitutes3|}}}    | [[Constitutes::{{{Constitutes3}}}| ]]}}{{#if: {{{Constitutes4|}}}    | [[Constitutes::{{{Constitutes4}}}| ]]}}{{#if: {{{Constitutes5|}}}    | [[Constitutes::{{{Constitutes5}}}| ]]}}{{#if: {{{Subject|}}}    | [[Is about::{{{Subject}}}| ]]}}{{#if: {{{Subject2|}}}    | [[Is about::{{{Subject2}}}| ]]}}{{#if: {{{Subject3|}}}    | [[Is about::{{{Subject3}}}| ]]}}{{#if: {{{Subject4|}}}  | [[Is about::{{Subject4}}}| ]]}}{{#if: {{{Subject5|}}}    | [[Is about::{{{Subject5}}}| ]]}}{{#if: {{{Subject6|}}}    | [[Is about::{{{Subject6}}}| ]]}}{{#if: {{{Subject7|}}}    | [[Is about::{{{Subject7}}}| ]]}}{{#if: {{{Subject8|}}}    | [[Is about::{{{Subject8}}}| ]]}}{{#if: {{{Subject9|}}}    | [[Is about::{{{Subject9}}}| ]]}}{{#if: {{{Subject10|}}}    | [[Is about::{{{Subject10}}}| ]]}}</includeonly>
+
</noinclude><includeonly>{{#if: {{{Description|}}} | {{Description|[[Description::{{{Description}}}]]}}}}{{#if: {{{KeyProperties|}}}|[[Has key properties::{{{KeyProperties}}}| ]]}}{{#if: {{{KeyPropertyHeaders|}}}|[[Has key property headers::{{{KeyPropertyHeaders}}}| ]]}}{{#if: {{{ON_constitutes|}}}    | [[ON_constitutes::{{{ON_constitutes}}}| ]]}}{{#if: {{{ON_cause|}}}    | [[ON_has_cause::{{{ON_cause}}}| ]]}}{{#if: {{{Constitutes|}}}    | [[Constitutes::{{{Constitutes}}}| ]]}}{{#if: {{{Constitutes2|}}}    | [[Constitutes::{{{Constitutes2}}}| ]]}}{{#if: {{{Constitutes3|}}}    | [[Constitutes::{{{Constitutes3}}}| ]]}}{{#if: {{{Constitutes4|}}}    | [[Constitutes::{{{Constitutes4}}}| ]]}}{{#if: {{{Constitutes5|}}}    | [[Constitutes::{{{Constitutes5}}}| ]]}}{{#if: {{{Subject|}}}    | [[Is about::{{{Subject}}}| ]]}}{{#if: {{{Subject2|}}}    | [[Is about::{{{Subject2}}}| ]]}}{{#if: {{{Subject3|}}}    | [[Is about::{{{Subject3}}}| ]]}}{{#if: {{{Subject4|}}}  | [[Is about::{{Subject4}}}| ]]}}{{#if: {{{Subject5|}}}    | [[Is about::{{{Subject5}}}| ]]}}{{#if: {{{Subject6|}}}    | [[Is about::{{{Subject6}}}| ]]}}{{#if: {{{Subject7|}}}    | [[Is about::{{{Subject7}}}| ]]}}{{#if: {{{Subject8|}}}    | [[Is about::{{{Subject8}}}| ]]}}{{#if: {{{Subject9|}}}    | [[Is about::{{{Subject9}}}| ]]}}{{#if: {{{Subject10|}}}    | [[Is about::{{{Subject10}}}| ]]}}</includeonly>

Revision as of 14:53, 3 January 2014

This template is for adding SMW data where no main template is in use. It should be used at the top of the page. It should not be used when a template is already in use that adds SMW data.
(So, not for {{website}}s, {{document}}s, {{event}}s, files or {{person}}s)
The only parameter displayed is the 'description'. - All the other parameters contribute only to the document's semantic mark up. The blue parameters not be marked up at all; they should be Wikispooks page names (whether or not the page yet exists).
The green parameters should be /-separated lists.
Usage:

{{SMWData
OPTIONAL DETAILS:
|ON_cause=a pagename which this subject caused according to the official narrative (Property:ON_has_cause)
|ON_constitutes=a pagename which this subject constitutes according to the official narrative (Property:ON_constitutes)
|Constitutes=a pagename which this subject constitutes (e.g. "censorship", "lone nut") (Property:Constitutes)
|Constitutes2...=
|Description=Document description
|Subject=The subject of the document
|Subject2, Subject3... =Extra subjects
|KeyProperties= Slash separated list of important properties of this page
|KeyPropertyHeaders= Slash separated list of property descriptions (same length as the above)
}}