Last modified: 2010-08-31 13:08:41 UTC
The handling of Type:Telephone number is a bit broken, both with regard to RFC3966, and with the display of the data tagged as such. RFC3966 states that a tel:-uri in the global-number-form should start with a +, followed by zero or more of '0' .. '9', '-', '.', '(', or ')', then a DIGIT, and then zero or more of the same characters as berfore the required digit. From what i can see in SMW_DV_URI.php the parser translates space to '-' when between digits, then removes all other spaces. Then calls isValidTelURI which doesnt recognize '(' or ')' as valid characters in the string. A more correct way would be to translate ' ' to '-' everywhere and then fold more than one '-' into a single one, and extend isValidTelURI to recognize '(' and ')' as it should. With regard to the display of these values I think it would be much better if a value tagges with a property of this type got shown as a link to the tel:-uri with the original text as the text shown, both in the page where it is defined and in semantic searches with #ask. A bonus would of course be pretty-printing of the value tagged with regard to national rules for correct digit-grouping and such. Some of these rules are quite easy to implement. In +47 we group numbers starting with 4, 8 and 9 as 3-2-3 and all other numbers as 2-2-2-2.