Template talk:ValueDescription
This template is used to get a well designed structure into the available tags that exist to describe a map feature.
There is no need to change the template itself if you just want to create a new Tag:somekey=whatever page or translate a existing page into your language!
Please read the instructions on this page to get a clue about how to use this template.
Contents |
How to use this template (new tag)
First create a new page with the name Tag:keyname=value for example Tag:highway=trunk or Tag:railway=subway.
At the top of this page include the template code:
{{ValueDescription|
key=keyname|
value=valuename|
image=Image:imagename.jpg|
description=short description|
onNode=yes/no|
onWay=yes/no|
onArea=yes/no|
lang=en|
combination=list of useful additional tags|
status=approval status}}
Replace the parts between the = and the | with something that fits your need.
- key= this is the name of your key in lower-case letters for example: key=highway
- value= this is the name of your value in lower-case letters for example: value=trunk
- image= name of a example image that describes your key for example: image=Image:Dscf0444 600.jpg. Setting "image=" with no image name will cause the category Feature pages with missing images to be added to the page and will add the No image yet image to the page. If you remove the image parameter entirely it will be assumed the tag doesn't require an image.
- description= short description of your key. try to keep it short but relevant. for example:description=Important roads that aren't motorways. Typically maintained by central, not local government.
- onNode= either yes or no describe on which element your key can be used
- onWay= either yes or no describe on which element your key can be used
- onArea= either yes or no describe on which element your key can be used
- lang= 2 letter country code for example de, en, nl, tr
- combination= bulletpointlist of additional tags that are usefull together with your tag. for example:
- combination=* [[Key:lanes|lanes]]
- * [[Key:oneway|oneway]]
- * [[Key:name|name]]
- * [[Key:reference|reference]]
- status= If this features has been proposed set the according value Approved, Rejected, Voting, Proposed, Draft or Abandoned
Once you finished this, you should start to fill the rest of your page. Try to explain as much as possible. Some examples can be seen on the existing pages.
Translating a existing page
If you like to translate a page into your language you just need to create a page for it for example De:Tag:highway=track. Once the page exist the link to this side will be seen on every *:Tag:highway=track site.
Do not edit this template to add the link to your translated page!
- Why don't we put the "Other Languages" table into another template (allowing parameter 1 to overwrite the title), so that all the different templates use the same block? It could be used 1.) in other languages and 2.) on other templates… -- MapFlea 15:36, 12 November 2008 (UTC)
- Yes, I also think it would be better to have a generic Template:Language! And like in Template:Language-mp (which should also be replaced) there should be no ifexist-tests. Whenever a translation-page exists can be seen by the color of the link. Parameters are not needed as we can use the {{PAGENAME}} variable. See mediawiki:Help:Magic_words --Phobie 15:58, 13 November 2008 (UTC)
Changes
Okay, so as you might have seen, I've been making a few minor changes to the template. Mostly so far just the addition of a onRelation= tag, and a few changes so that some fields don't get displayed if the variable isn't declared. For instance, if you use image= you get the 'No image yet' image as before, but if you don't include the image= parameter at all, then no image is included. This is useful where having an image wouldn't really add much to people's understanding of the key-value, and so displaying 'no image yet' isn't that helpful.
Other changes I think might be useful, but which I haven't implemented yet, are:
- include some of the tagwatch count data directly in the infobox itself (would have to be updated occasionally though).
- remove the link to Wikipedia 'definition', or at least make this optional. I find that it doesn't really add much in most cases, and we should be 'defining'/describing the tag on the page itself.
- remove link to 'user discussion'. There's already a tab for this!
- find some way of minimising all the links to tagwatch. these are very useful, but take up a lot of the box.
- adding images of how the tag is rendered in some of the popular map styles (Mapnik/Osmarender/cycle maps/etc).
- rename 'Useful combination' as 'Often used in combination with' (or similar).
- Make the node/way/area tags link to pages describing those elements, rather than their image pages (really need the Icon extension to do this easily).
Any thoughts/objections?
Frankie Roberto 20:57, 22 February 2009 (UTC)
- I agree with removing definition and especially discussion links. The definitions aren't necessarily helpful -- the relevant definition is the one given by the page itself, not by some external sources. If external links (e.g. to Wikipedia) are useful, they are commonly provided anyway (using the [[wikipedia:foo]] syntax). Using the icons as links to element pages is probably a good idea, too.
- I don't agree wih including tagwatch information in the box, especially if it would require page updates to keep the info up to date. You couldn't put all the information from tagwatch in that box anyway, and a single click really isn't too much effort.
- I also don't agree with "Often used in combination with", because I believe that this section shouldn't simply be based on usage statistics (again, we have Tagwatch for that), but on the page authors' human intelligence.
- Btw, could you please apply the changes you made so far to Template:KeyDescription, too? --Tordanik 11:56, 23 February 2009 (UTC)
Categorisation Change
I changed
<includeonly>[[Category:{{{lang|en}}}:Tags|{{{key}}}]][[Category:Tags_by_value|{{{value}}}]]
{{#if: {{{image|}}} ||[[Category:Feature pages with missing images]]}}</includeonly>
to
<includeonly>{{#ifeq: {{lc:{{#ifeq: {{{lang|en}}}|en||{{{lang}}}:}}Tag:{{{key}}}.3D{{{value}}}}} | {{lc:{{anchorencode:{{FULLPAGENAME}}}}}} |[[Category:{{{lang|en}}}:Tags|{{{key}}}]][[Category:{{{lang|en}}}:Tags_by_value|{{{value}}}]]|}}{{#if: {{{image|}}} ||[[Category:Feature pages with missing images]]}}</includeonly>
to only categorise pages with names in the format (lang:)Tag:(key)=(value) in the first two categories. I didn't change the bit about the image. This change was also added to the De, Fi and Pt versions of this page to keep categorisation consistent. The template was also being used in Proposed Features pages which didn't really seem to fit the category properly. The .3D and the anchorencode: were to handle spaces in page names where there were underscores in keys or values. It also then categorised the tags_by_value by language as was already the case with the tags category. --EdLoach 23:40, 25 June 2009 (UTC)
→ So it appears that the auto-categorization remains non-functional, correct? My apologies, I was looking at implementation on the improperly named page Key:access:bdouble; this function works after moving the page to Tag:access=bdouble. --Ceyockey 14:34, 11 November 2010 (UTC)
seeAlso Change
Added See also section for seeAlso parameter. See Tag:boundary=administrative for an implementation. FrViPofm 11:19, 21 September 2009 (UTC)