| Status: | effective |
| Progress: | 100% |
| Version: | 7.0.0+ |
$smwgCategoriesAsInstances
| Configuration parameter details: | |||
| Name | $smwgCategoriesAsInstances | ||
| Description | Sets whether a category statement should be treated as an element of the category | ||
| Default setting | true |
||
| (Other) available settings |
|
||
| Software | Semantic MediaWiki | ||
| Since version | |||
| Until version | still available | ||
| Configuration | Query settings | ||
| Keyword | category · inclusion · category hierarchy · subcategory · hierarchy inferencing | ||
$smwgCategoriesAsInstances is a configuration parameter that sets whether a category statement like e.g. [[Category:Foo]] should be treated as an element of the category "Foo". The configuration parameter was introduced in Semantic MediaWiki 1.5.0Released on 7 March 2010 and compatible with MW 1.14.x - 1.17.x. and deprecated with Semantic MediaWiki 3.0.0Released on 11 October 2018 and compatible with MW 1.27.0 - 1.31.x.1.
$smwgCategoriesAsInstances to its replacement has been removed, so this setting is now silently ignored. Migrate to configuration parameter $smwgCategoryFeaturesSets the behaviour of the query features related to category handling (option 'instance') in "LocalSettings.php".2
Default setting
$smwgCategoriesAsInstances = true;
This means that category statements being treated as elements of the category, e.g. [[Category:Foo]] should be treated as an element of the category "Foo".
Changing the default setting
To modify the setting to this configuration parameter, add one of the following lines to your "LocalSettings.php" file:
- Disable category statements being treated as elements of the category
$smwgCategoriesAsInstances = false;
This means that category statements are not being treated as elements of the category thus making it impossible to make category pages elements of other categories.
See also
- Help page on subcategory inferencing
- Help page on configuration parameter
$smwgUseCategoryHierarchySets whether elements of the subcategory hierarchy are considered as hierarchy elements in the annotation process - Help page on configuration parameter
$smwgQSubcategoryDepthSets the maximum level of subcategory inclusion (steps within category hierarchy) when querying - Help page on configuration parameter
$smwgCategoryFeaturesSets the behaviour of the query features related to category handling
References
- ^ Semantic MediaWiki: GitHub pull request gh:smw:2806
- ^ | | | | | | | | | Semantic MediaWiki: GitHub pull request gh:smw:6706