Module talk:Mapframe

Copying template to another language wiki
Hi, I would like to request that this template, together with its dependencies be copied over to the Bulgarian wiki. There are a lot of pages that would benefit from it and there is currently no alternative template to use. The parameters can be left as is, but if needed I can translate them over.

broken map link
Is it just me or does infobox mapframe not work at Sokolac Fortress (Bihać)? I don't see why, it links to https://www.wikidata.org/wiki/Q25555219 which in turn links to https://www.openstreetmap.org/relation/14304925 so it all seems fine...? --Joy (talk) 09:57, 23 February 2024 (UTC)


 * Have fixed. Regards, The Equalizer (talk) 03:51, 24 February 2024 (UTC)
 * @The Equalizer you fixed it? Thanks, but what was the trick, for future reference? --Joy (talk) 19:52, 24 February 2024 (UTC)
 * Because Infobox mapframe was used standalone in the Infobox military installation template of the page, and the Wikidata entry had both the P625 point and P402 shape attributes (which reserves a space on the Wiki Map servers to save a map), it defaults to only trying to show the shape unless extra parameters are specified such as  or   to show a marker. However, the map was centring on 0,0 coordinates in the Atlantic Ocean.
 * That's because there was no actual shape stored on the Wiki map servers that mirror OpenStMap, as the  parameter for the shape on OSM needs to be one of four (mw:Help:Extension:Kartographer/OSM) that causes the shape to be migrated across and so be available. I figured it is nicer to have that available than a simple marker, and set   as boundary. Regards, The Equalizer (talk) 21:37, 24 February 2024 (UTC)
 * Ohh, so the previous OSM type of "building" was the bad part... Would it make sense to add hints to this effect somewhere in Template:Infobox mapframe/doc or Template:Maplink/doc? We seem to document a lot of the other aspects of the Kartographer extension but not this. --Joy (talk) 16:03, 25 February 2024 (UTC)
 * The OSM Media Wiki page I referenced above was in Template:Maplink/doc and in #4 of Module talk:mapframe/FAQ (which is at the top of Template talk:Infobox mapframe). Trouble is, they are all sprawling documents and it's hard to pick out the specifics at times. I've added the FAQ link to them all and updated it with the fourth type parameter. Regards, The Equalizer (talk) 22:59, 25 February 2024 (UTC)
 * Oh yeah, I would not really expect anyone to look for template documentation at template talk. This FAQ should be transcluded into the standard template/module/whatever documentation element, putting it on Talk is tantamount to hiding it, which seems counterproductive :D Done that now. --Joy (talk) 09:19, 26 February 2024 (UTC)
 * I note the relation for this shape has changed so it will need redefining on OSM @Joy - not signed in on OSM at the moment as not home. Regs The Equalizer (talk) 07:52, 31 May 2024 (UTC)
 * Interesting, https://www.openstreetmap.org/relation/14304925 says version #5 was a deletion described as "Modified multipolygon #RelationsCleanup". So I guess we're supposed to clean up after the cleanup? :D I guess I'll make Wikidata use https://www.openstreetmap.org/relation/16821352 now --Joy (talk) 12:18, 31 May 2024 (UTC)
 * It's OSM that needs the update... I've done this now. Give it a day... Regs, The Equalizer (talk) 18:46, 31 May 2024 (UTC)
 * Now displaying. Regs, The Equalizer (talk) 01:31, 1 June 2024 (UTC)

question about switching between maps
I'd like to switch between several different .map files depicting the same region in different times. I tested the template:switcher and the switch function described in the template:mapframe docs. Neither of them worked. The template:switcher just resulted in 3 identical maps (the first of the three maps). The template:mapframe switch function resulted in a map without the associated shapes on top. But it's possible I did it wrong. Here's the code segment for that attempt:

I also tried adding overlapping shapes in the same map file and trying to switch by ID. That threw errors. Anyone done or seen something like this before? If I can see a working version I can probably reconstruct it. -- Asdasdasdff (talk) 22:37, 1 March 2024 (UTC)


 * Use instead to allow an overlay:
 * (Remove any colons seen)
 * Also you report having three identical maps. You should look at the map files on Commons.
 * commons:Data:Wisconsin's 1st Assembly district (2024–2031).map
 * and
 * commons:Data:Wisconsin's 1st Assembly district (2022–2023).map
 * I've compared the coordinate data and they both exactly the same.
 * commons:Data:Wisconsin's 1st Assembly district (2011–2021).map is subtly different, a small change at the bottom right of the shape.
 * The Equalizer (talk) 17:39, 2 March 2024 (UTC)
 * Thank you, I will try that out! And yeah, the 2024 map is actually identical to the 2022 map.  But I guess I thought it was necessary to indicate that even though the map was unchanged, it was under a new legal authority with the 2024 law vs the 2022 court decision (district 1 is the only district that was left unchanged).  Thanks again. -- Asdasdasdff (talk) 23:04, 3 March 2024 (UTC)
 * Hey, looks like it worked! Thanks again! -- Asdasdasdff (talk) 23:09, 3 March 2024 (UTC)
 * Thank you, I will try that out! And yeah, the 2024 map is actually identical to the 2022 map.  But I guess I thought it was necessary to indicate that even though the map was unchanged, it was under a new legal authority with the 2024 law vs the 2022 court decision (district 1 is the only district that was left unchanged).  Thanks again. -- Asdasdasdff (talk) 23:04, 3 March 2024 (UTC)
 * Hey, looks like it worked! Thanks again! -- Asdasdasdff (talk) 23:09, 3 March 2024 (UTC)

geojson color styling ignored for data file in subdirectory
While the preview works for both static rendered images behave differently.

I have raised a bug(T359705). This comment is to demonstrate the issue. Arjunaraoc (talk) 05:40, 9 March 2024 (UTC)


 * Today I find that the color styling is updated to correct color for the data file in sub directory. The issue may need investigation for delay in updation. Arjunaraoc (talk) 03:56, 10 March 2024 (UTC)

Styling rendered with file in root directory
 { "type": "ExternalData", "service": "page", "title": "Veligonda_Project.map" }

styling rendered for file in sub directory
 { "type": "ExternalData", "service": "page", "title": "Andhra Pradesh/Veligonda_Project.map" } Surprisingly, the static image for data in sub directory was not updated even after two days, when I tested in actual article page.


 * I think there is a caching delay of some sort. I tried updating a file I was working with in a sandbox (so in a subdirectory too) and although it shows ok on Commons it also wouldn't seemingly show the new attributes when used in an article. Even purging hasn't helped. A workaround is to update and then move the file to a new page. The Equalizer (talk) 05:27, 15 March 2024 (UTC)

Inserting textual markers
Hi, is there any way to place textual markers? For example to show different faculties of Sharif university we need textual markers, i.e., for:

Hooman Mallahzadeh (talk) 07:23, 12 April 2024 (UTC)
 * a textual marker for Electrical faculty, another for Computer faculty etc. is needed. How can I mark them with pointers? Thanks,


 * You can't have points that show text on top of the thumbnail map on infobox mapframe or mapframe Kartographer based maps, only when they are clicked on in full screen. If you want multiple points, have to use mapframe only. So:






 * Regards, The Equalizer (talk) 22:36, 12 April 2024 (UTC)
 * @The Equalizer I really propose to implement textual markers. And I don't think its implementation would be hard. Such textual markers are really helpful. Do you agree? Hooman Mallahzadeh (talk) 05:38, 13 April 2024 (UTC)
 * Alternatively you can use the older map tools at Maps for Wikipedia. If to be proposed, search Phab first as I am certain this will have been asked before, there likely may even be an open request for it. I am unsure why the powers that be chose to go with the icons only, maybe as going forward it was to be implemented as an update. The Equalizer (talk) 08:13, 13 April 2024 (UTC)

Language
I hope this is the right venue. Why do some maps, e.g. at Merkin Hall and Metropolitan Opera House (Lincoln Center) (see right), show some landmarks, e.g. Linkoln Skver, Kolambus Serkl, Hels Kičen, Lenoks Hil …, in a language that may be Slovenian or another Slavic language? -- Michael Bednarek (talk) 12:05, 8 May 2024 (UTC)
 * It seems to be a general problem with the Open Street Maps base map. I took the map at Alabama and found the same when navigating to Manhattan. —  Jts1882 &#124; talk 13:44, 8 May 2024 (UTC)
 * Seems it's an old problem resurfacing. It's being discussed at Village_pump_(technical) and . —  Jts1882 &#124; talk 15:55, 8 May 2024 (UTC)

Second point does not show up
For some reason, everything beyond the first point does not show up:

Strangely, if I insert a dummy shape as the second item, it works:

intforce (talk) 12:36, 30 May 2024 (UTC)

All the points are there when the map is expanded to full screen, it's the thumbnail autozoom that isn't working. By way of example I have reused your first map and manually added zoom and coordinates without a dummy shape parameter, which is a workaround for now. A similar fault with geomasks was reported on Phab couple years back at, have added an extra note about this. Regs, The Equalizer (talk) 22:57, 30 May 2024 (UTC)


 * Thank you! intforce (talk) 23:08, 30 May 2024 (UTC)


 * One of the chaps on Phabricator spotted that if id1=/type1=/title1= instead of id/type/title it works fine. Not documented clearly on the template page. Regs, The Equalizer (talk) 18:56, 31 May 2024 (UTC)