Customization: Difference between revisions

From SemanticOrganization
Jump to: navigation, search
(Created page with "=== Using your own template === * Create a new page in the template namespace. You best start by copying the content of the template you want to replace. * Change <code>Media...")
 
No edit summary
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
{{semorg-docs}}
* [[Customize Lists]]
=== Using your own template ===
=== Using your own template ===


Line 13: Line 16:
** <code>MediaWiki:Semorg-field-''templatename''-''propertyname''-help</code>, if you want to show a help message,
** <code>MediaWiki:Semorg-field-''templatename''-''propertyname''-help</code>, if you want to show a help message,
* Create your own template, add the field to the <code>{{#semorg-set}}</code> call.
* Create your own template, add the field to the <code>{{#semorg-set}}</code> call.
=== Change the appearance of lists ===
To change the defaults:
* Change <code>MediaWiki:Semorg-list-''templatename''-headers</code>
* Change <code>MediaWiki:Semorg-list-''templatename''-row-template</code>
Customized call of <code>{{#semorg-list:''templatename''}}</code>
* use parameter <code>category</code>
* use parameter <code>query</code>
* use parameter <code>row template</code>
* use parameter <code>sort</code>
* use parameter <code>order</code>
* use parameter <code>default</code>
* use parameter <code>limit</code>
* use parameter <code>headers</code>
* use <code>?''property''=''name''</code> to add custom query fields

Latest revision as of 22:48, 27 September 2020

This page is part of semorg's documentation.

Using your own template

  • Create a new page in the template namespace. You best start by copying the content of the template you want to replace.
  • Change MediaWiki:Semorg-templatename-template to the name of the newly created template.

Adding new fields

  • Create your new property using the following naming convention: semorg-templatename-propertyname (you can use Special:CreateProperty to do so).
  • To add the property to your form add propertyname to MediaWiki:Semorg-form-template-rows
  • The appearance of the field in the form can be influenced by the following messages:
    • MediaWiki:Semorg-field-templatename-propertyname-name for the form field's label
    • MediaWiki:Semorg-field-templatename-propertyname-parameters, if you want to add parameters to the {{{field}}} definition
    • MediaWiki:Semorg-field-templatename-propertyname-help, if you want to show a help message,
  • Create your own template, add the field to the {{#semorg-set}} call.