Con­figu­ration para­meter "$smwgPDefaultType"

From semantic-mediawiki.org
Configuration parameter details:
Name $smwgPDefaultType
Description Sets the default datatype for a property if it was not defined manually
Default setting
_wpg
Software Semantic MediaWiki
Since version
Until version still available
Configuration Miscellaneous
Keyword property · datatype


$smwgSubPropertyListLimit is a configuration parameter that sets the default datatype for an undefined property, i.e. if the datatype was not specified by adding special property "Has type"Assigns a datatype to a property to the respective property's page. The configuration parameter was introduced in Semantic MediaWiki 1.1.2Released on 14 June 2008 and compatible with MW 1.10.x - 1.13.x..

Default setting[edit]

$smwgPDefaultType = '_wpg';

This means that by default all undefined properties, i.e. those without pages or whose pages have no "has type" statement, will be assumed to be of datatype "Page"Holds names of wiki pages, and displays them as a link specified by the corresponding internal datatype ID.

Changing the default setting[edit]

To modify this configuration setting, add one of the following lines to your "LocalSettings.php" file after the enableSemantics() call:

Replace the default datatype "Page" by datatype "Text"
$smwgPDefaultType = '_txt';
Under regular circumstances settings other than '_wpg' or '_txt' are not recommended.
After changing the setting for this configuration parameter the semantic data have to be rebuild either via the command line using maintenance script "rebuildData.php"Allows to rebuild all the semantic data for a selected data backend/store or by triggering the special task "Data repair and update" by clicking the button labeled "Start updating data" in the "Data repair and update" section on special page "SemanticMediaWiki"Provides functions for wiki administrators that assist in doing their administration work.

List of internal datatype IDs[edit]

The internal datatype IDs are specified in the files located at "/i18n/extra/XX.json".

See also[edit]