Page MenuHomePhabricator

Accept rtsp links for URL-type properties
Closed, ResolvedPublic

Description

Author: florian.dufour

Description:
Patch

Hi,

Would it be possible to accept "rtsp://..." URLs for URL-type properties ? As for now, we can just use http, https and ftp URLs.

A patch is attached.


Version: unspecified
Severity: normal

Attached:

Details

Reference
bz26609

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 11:14 PM
bzimport set Reference to bz26609.

Hi,

Thanks for the patch; this has now been added to Semantic Forms, in SVN.

Stupid question (coming from someone who doesn't know anything about semantic forms), but wouldn't you want this to be consistent with what mediawiki is configured to consider to be a URL? Mediawiki even outputs a wgUrlProtocols js variable for that purpose.

Bawolff - that's a reasonable suggestion, although I'm not sure that the set of allowed prefixes for MediaWiki and the set of allowed prefixes for Semantic MediaWiki will always be the same. For instance, MediaWiki treats "mailto:" URLs as standard URLs, while I don't know if SMW does, or should (there's a separate data type for email addresses). I'm adding Markus as a CC - Markus, do you have any thoughts on the matter?

SMW has only very little restrictions on the URIs that can be used. If a URI used in SMW is not using one of MediaWiki's supported protocols then this simply means that SMW will not print it in [ ] (since this only works properly if the protocol is allowed in MW). But the value is accepted in any case, so there is no need to worry about SMW here. If URI validation was to be extended, then SMW would add more checks for allowed URL structures and characters but not restrict the protocol.

The purpose of Type:Email mainly is to make the mailto optional whereas proper URLs must always specify a protocol explicitly.