$smwgURITypeSchemeList

From semantic-mediawiki.org


Configuration parameter details:
Name $smwgURITypeSchemeList
Description Sets the permissive URI schemes for data values to properties of datatype URL and Annotation URI
Default setting See below
Software Semantic MediaWiki
Since version
Until version still available
Configuration Basic settings · Installation
Keyword url · uri · uri schema


$smwgURITypeSchemeList is a configuration parameter that sets the permissive URI schemes for data values to properties of datatype "URL"Holds URIs, URNs and URLs and datatype "Annotation URI"Holds URIs, but has some technical differences during export compared to the "URL" type to allow for better validation. The configuration parameter was introduced in Semantic MediaWiki 3.0.0Released on 11 October 2018 and compatible with MW 1.27.0 - 1.31.x.1 and extended by "git", "irc", "ircs", "sftp" and "ssh" in Semantic MediaWiki 3.0.1Released on 25 January 2019 and compatible with MW 1.27.0 - 1.31.x..2

Default setting[edit]

$smwgURITypeSchemeList = [
	'http', 'https', 'mailto', 'tel', 'ftp', 'sftp', 'news', 'file', 'urn',
	'telnet', 'ldap', 'gopher', 'ssh', 'git', 'irc', 'ircs'
];

This means that data values containing the URI schemes listed may be added to properties of datatype "URL"Holds URIs, URNs and URLs and datatype "Annotation URI"Holds URIs, but has some technical differences during export compared to the "URL" type.

Changing the default setting[edit]

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

Extend the list by "xmpp" for Jabber links
$smwgURITypeSchemeList = array_merge(
	$smwgURITypeSchemeList, [
		'xmpp'
	]
);
Only allow "http", "https", "mailto" and "tel"
$smwgURITypeSchemeList = [
	'http', 'https', 'mailto', 'tel'
];

See also[edit]


References

  1. ^  Semantic MediaWiki: GitHub pull request gh:smw:2842
  2. ^  Semantic MediaWiki: GitHub pull request gh:smw:3566