Help:Configuration parameter "$smwgEnabledInTextAnnotationParserStrictMode"

From semantic-mediawiki.org
Jump to: navigation, search
edit with form


Title $smwgEnabledInTextAnnotationParserStrictMode
Description Sets whether strictness should be enforced during the annotation parsing process
Default setting
true
(Other) available settings
false

Allows to disable strictness during the annotation parsing process

Software Semantic MediaWiki
First version supported
Last version supported still available
Configuration Installation
Keyword parser · in-text annotation · multi property value

$smwgEnabledInTextAnnotationParserStrictMode is a configuration parameter that sets whether strictness should be enforced during the annotation parsing process. The configuration parameter was introduced in Semantic MediaWiki 2.3.1Released on 4 January 2016 and compatible with MW 1.19.0 - 1.25.x..1

Default setting

$smwgEnabledInTextAnnotationParserStrictMode = true;

This means that only a single triple such as e.g. [[PropertyName::ProperyValue::alsoPartOfThePropertyValue]] is being assumed (strict interpretation), i.e. the property value "ProperyValue::alsoPartOfThePropertyValue" is being added to a property called "PropertyName".

Changing the default setting

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

Disable the strict interpretation of annotations
$smwgEnabledInTextAnnotationParserStrictMode = false;

This means that multiple properties can be assigned using a [[PropertyName1::PropertyName2::PropertyValue]] notation. Thus the property value "PropertyValue" is being added to the properties called "PropertyName1" and "PropertyName2". This however may cause value strings to be interpret unanticipated in case of additional colons.

See also

References

  1. ^  Semantic MediaWiki: GitHub issue gh:smw:1252