| Configuration parameter details: | |
| Name | $smwgAdminFeatures |
| Description | Sets which administrative features may be used via special page "SemanticMediaWiki" |
| Default setting | See below |
| Software | Semantic MediaWiki |
| Since version | |
| Until version | still available |
| Configuration | Installation |
| Keyword | special page · administration · gardening · setup · store setup · data repair · data rebuild · object-id lookup · object-id disposal |
$smwgAdminFeatures is a configuration parameter that sets which administrative features may be used via special page special page "SemanticMediaWiki" allowing fine grained control. The configuration parameter was introduced in Semantic MediaWiki 2.5.0Released on 14 March 2017 and compatible with MW 1.23.0 - 1.29.x.1 and deprecated configuration parameter $smwgAdminRefreshStoreSets whether it is possible to set up the database tables or to initiate the repairing or updating of all semantic data of wiki using the interface on special page "SemanticMediaWiki".2
SMW_ADM_* constants. The constant form still works but is deprecated and will be removed in Semantic MediaWiki 8.0.0Released on an unknown date and compatible with unknown versions of MediaWiki..3
Default setting[edit]
$smwgAdminFeatures = [ 'refresh', 'setup', 'disposal', 'pstats', 'fullt', 'maintenance-script-docs', 'show-overview', 'alert-last-optimization-run' ];
This means that by default all users who are administrators (user group "sysop") or Semantic MediaWiki administrators (user group "smwadministrator") may use all features available.
Available options[edit]
'refresh'(formerlySMW_ADM_REFRESH) – Allows to initiate the repairing or updating of all semantic data on the wiki.'setup'(formerlySMW_ADM_SETUP) – Allows to set up or upgrade the database tables used to store semantic data on the wiki.'disposal'(formerlySMW_ADM_DISPOSAL) – Allows to lookup and dispose of outdated semantic objects.'pstats'(formerlySMW_ADM_PSTATS) – Allows to initiate the rebuild of property statistics on the respective property pages as well as on special page "Statistics" displaying semantic statistics.'fullt'(formerlySMW_ADM_FULLT) – Allows to initiate the rebuild of the search index for the full-text search feature.'maintenance-script-docs'(formerlySMW_ADM_MAINTENANCE_SCRIPT_DOCS) – Shows the maintenance scripts documentation tab.'show-overview'(formerlySMW_ADM_SHOW_OVERVIEW) – Shows the Overview tab.'alert-last-optimization-run'(formerlySMW_ADM_ALERT_LAST_OPTIMIZATION_RUN) – Allows to see a maintenance alert in case a database optimization run done with maintenance script "setupStore.php"Allows to set up the data backend/store is overdue.4
Changing the default setting[edit]
To modify the setting to this configuration parameter, add one of the following lines to your "LocalSettings.php" file:
- Removing a specific administrative function
To remove a specific administrative function e.g. the ability to initiate the repairing or updating of all semantic data on the wiki, just exclude the respective string as shown just above:
$smwgAdminFeatures = [ 'setup', 'disposal', 'pstats', 'fullt', 'maintenance-script-docs', 'show-overview', 'alert-last-optimization-run' ];
- Removing all administrative functions
To remove all administrative features set an empty array:
$smwgAdminFeatures = [];
Legacy constant form (deprecated since 7.0.0)[edit]
The default expressed with constants:
$smwgAdminFeatures = SMW_ADM_REFRESH | SMW_ADM_SETUP | SMW_ADM_DISPOSAL | SMW_ADM_PSTATS | SMW_ADM_FULLT | SMW_ADM_MAINTENANCE_SCRIPT_DOCS | SMW_ADM_SHOW_OVERVIEW | SMW_ADM_ALERT_LAST_OPTIMIZATION_RUN;
A specific feature can be removed with a bit-operation, e.g.:
$smwgAdminFeatures = ( $smwgAdminFeatures & ~SMW_ADM_REFRESH );
To remove all administrative features with the constant form, use SMW_ADM_NONE:
$smwgAdminFeatures = SMW_ADM_NONE;
Preventing access to special page "SemanticMediaWiki"Provides functions for wiki administrators that assist in doing their administration work[edit]
To achieve this the user right "smw-admin" has to removed from the wiki administrators (user group "sysop") and additionally no user should be assigned to be a Semantic MediaWiki administrator (user group "smwadministrator"). This will additionally prevent the display of operational statistics and of configuration settings.
See also[edit]
- Help page on configuration parameter
$smwgCreateProtectionRightSets the user right required to create new properties for another user related permission setting - Help page on configuration parameter
$smwgAdminRefreshStoreSets whether it is possible to set up the database tables or to initiate the repairing or updating of all semantic data of wiki using the interface on special page "SemanticMediaWiki" - Help page on special page "SemanticMediaWiki"Provides functions for wiki administrators that assist in doing their administration work formerly known as special page "SMWAdmin"
References
- ^ Semantic MediaWiki: GitHub pull request gh:smw:2142
- ^ Semantic MediaWiki: GitHub issue gh:smw:2343
- ^ | | | | | | | | | Semantic MediaWiki: GitHub pull request gh:smw:6793
- ^ Semantic MediaWiki: GitHub pull request gh:smw:4476
- ^ Bitwise Operators to use parentheses to ensure the desired precedence ...