Difference between revisions of "Template:Invert-property"

From MarineLives
Jump to: navigation, search
(Created page with "<noinclude> This template takes a property name and its inverse property name. It queries for the inverse property name and produces wiki text with the inverted annotations....")
 
 
(5 intermediate revisions by the same user not shown)
Line 6: Line 6:
 
This hides the annotation by specifying blank as the alternate text.  Since "<tt>| </tt>" in a template confuses parsing, it uses a subtemplate [[Template:Invert-property/Separator]] for the separator.
 
This hides the annotation by specifying blank as the alternate text.  Since "<tt>| </tt>" in a template confuses parsing, it uses a subtemplate [[Template:Invert-property/Separator]] for the separator.
  
See [[California]] for use of this template.
+
See xxxx for use of this template.
  
 
(Credit goes to Semantic MediaWiki user DanTMan for this technique.)
 
(Credit goes to Semantic MediaWiki user DanTMan for this technique.)
[[Category:Sample pages]]
+
 
 
</noinclude><includeonly>[[{{{2}}}::{{#ask:[[{{{1}}}::{{PAGENAMEE}}]]|link=none|sep={{Invert-property/Separator|{{{2}}}}}}}|  
 
</noinclude><includeonly>[[{{{2}}}::{{#ask:[[{{{1}}}::{{PAGENAMEE}}]]|link=none|sep={{Invert-property/Separator|{{{2}}}}}}}|  
 
]]</includeonly>
 
]]</includeonly>
 +
 +
[[Category:Template]]

Latest revision as of 14:15, August 4, 2016


This template takes a property name and its inverse property name. It queries for the inverse property name and produces wiki text with the inverted annotations.

Usage: {{Invert-property|Derived property name|Its inverse property name}}

This hides the annotation by specifying blank as the alternate text. Since "| " in a template confuses parsing, it uses a subtemplate Template:Invert-property/Separator for the separator.

See xxxx for use of this template.

(Credit goes to Semantic MediaWiki user DanTMan for this technique.)