Wikivoyage:Arrivals lounge/Archives/2021/November
Appearance
This is an archive of past discussions. Do not edit the contents of this page. If you wish to start a new discussion or revive an old one, please do so on the current talk page. |
Wikidata integration
So I'm a bit confused as to why the below shows a link to Wikipedia for Mombasa only, despite both Mombasa and Nairobi being linked to Wikipedia correctly (on Wikidata). The same code does work as expected on de.wikivoyage.com.
Bugsinmyfood (talk) 07:24, 6 October 2021 (UTC)
- The marker points to https://www.wikidata.org/wiki/Q225641. The article points to https://www.wikidata.org/wiki/Q1112885. Markers show the Wikipedia link only when the Wikidata ID link does not match the Wikivoyage article. Otherwise we want readers to go to our article, rather than being directed to Wikipedia immediately. --Nelson Ricardo (talk) 20:53, 6 October 2021 (UTC)
- Interesting! I can see the reasoning behind that. Do you know where I can find documentation for this? Template:Marker/doc has nothing on the output logic, e.g. which fields are shown when. Bugsinmyfood (talk) 12:56, 7 October 2021 (UTC)
- Absent documentation, someone who understands the code at https://en.wikivoyage.org/w/index.php?title=Template:Marker&action=edit would need to explain it. --Nelson Ricardo (talk) 01:36, 8 October 2021 (UTC)
- I can explain it: the marker template consits so: |type is the type of listing, |name is the name of the listing, and |wikidata can add the lat/long fields.If not, then use |lat for the lat, and |long for the long. Optional are |zoom, that changes the zoom level, |url for the url of the listing, and |image for a image linked to it. Now, these are examples:1 Museum 1 Theme Park The rest is explained at Template:Marker. DhrGabriel contribs 16:00, 12 October 2021 (UTC)
- Interesting! I can see the reasoning behind that. Do you know where I can find documentation for this? Template:Marker/doc has nothing on the output logic, e.g. which fields are shown when. Bugsinmyfood (talk) 12:56, 7 October 2021 (UTC)
- The point is that the Wikidata parameter does some magic, which is not explained: it sometimes add the Wikidata icon and link (not in markers), sometimes the Wikipedia icon and link and sometimes coordinates (when none are explicitly given and Wikidata has them). The magic is sometimes complex, such as when there is a mismatch in Wikidata coupling. Some of it is puzzling people from time to time and should be explained on the /doc page. –LPfi (talk) 11:11, 4 November 2021 (UTC)
Numbering in listing
Hello, In this page, we have numbering on the listings of "See" and "Eat" section, but not in "Sleep" section. How to have that numbering there?Lightbluerain (talk) 08:04, 4 November 2021 (UTC)
- The numbers show up when longitude/latitude geocoding is added to a listing. Have a look at the listings that are numbered in edit mode to see the format that's used for geocoordinates on this site, and thanks! Ikan Kekek (talk) 08:36, 4 November 2021 (UTC)
- In some cases listings link to Wikidata items, and then coordinates are fetched from there if none are given explicitly in the listing, and then the number shows up. This is common e.g. for Grand old hotels. –LPfi (talk) 11:14, 4 November 2021 (UTC)