Discuss $smwgPageSpecialProperties
- [View source↑]
- [History↑]
Contents
Thread title | Replies | Last modified |
---|---|---|
Renaming special property | 6 | 15:45, 10 February 2014 |
In my wiki, one special property (Creation date, Дата создания in Russian localisation) collided with a property of the same name created earlier. Is there a simple way to rename the special property?
I believe it is "just" a matter of changing the translation in SMW_LanguageRu.php. However this is strongly discouraged and you will have to do it every time you upgrade. The better solution is to change the individually created property once.
I think if the names for special properties, types, namespaces, etc. were configurable--in LocalSettings.php or, better, by editing a MediaWiki message--that would be more MediaWiki way.
If I edit the translation at TranslateWiki replacing Дата создания with Дата создания страницы (literally, Page creation date), will it ever make into SMW release and will it not infringe on anyone's interests?
Well it will definitively cause problems for the wikis which already use the special property. It's there for over a year now so chances are high. Additionally special properties, datatypes and namespaces are currently not localizable via translatewiki.net, but this is another issue.
I'd like to point out that this is not only problem of one localisation or one property. This (and potentially some other) name for the special property is not specific to wiki or SMW in any localisation and therefore is bound to cause conflicts. There are some production SMW sites for quite a long time already.
In my humble opinion, the best solution would be to work out a policy for naming special properties that would prevent conflicts--like, adding the word page's or file's, or even prepending a double underscore to all names, while giving to those already quering special properties the opportunity to rename them in LocalSettings.php.
I think a general recommendation on how to name properties will be of great help here. Property naming tends to be a total mess. From experience I would probably never create a custom property just named "Creation date" as you yourself would not in the meantime since it is destined to conflict not only with special properties but other possible custom use cases on a wiki. I myself did occasionally fall flat on my face, too. However starters do not have this experience an you cannot blame them at all, so that's the issue I believe.