Topic on Extension talk:MultiMaps/Flow

Cojoilustrado (talkcontribs)

Can we center with this extension? Or define a place along with the coordinates? Instructions say we might be able to use parameters from Maps extension but so far any combination I tried failed.

FellTiger (talkcontribs)

You can center the map around a given coordinate by writing {{#multimaps:1, 2}}. This extension does not offer any geocoding (i.e. place names are not recognized).

The documentation says that the parameter syntax is aimed to be compatible. It means that if both extensions offer a feature it is very likely that the same wiki markup is used. For example the code for displaying OpenStreetMap in a Leaflet frame at N10° and E10° is similar:
{{#display_map: 10, 10 }}
{{#multimaps: 10, 10 }}

What are you trying to achieve? Maybe I can help you.

2605:E000:1301:5631:2D7C:3B8F:5544:A57B (talkcontribs)

Thanks for the reply. I have a wiki about Venezuela and every city, town and state has an infobox with a multimap. This is all good, the thing is that when a map is displayed for, let's say, a town, the map center on the town, which is ok, but I'd like to keep the map centered on the state. So we see the whole state with the marker over the position of the town. Am I making sense?

FellTiger (talkcontribs)

You can achieve this by using position, center, and zoom like in this example: {{#multimaps: 10,10|center=10.264,9.9957628|zoom=10}}. It produces a map with a marker at 10,10. The map is centered at 10.264,9.9957628 and it is zoomed to level 10.

Cojoilustrado (talkcontribs)

The center parameter did it. For some reason I had to tinker with it more than usual, but it's working now. Here's what I'm using in case anyone is looking for a solution.

{{#multimaps: {{{coordenadas|8.8919987,-64.1848373}}}|{{#if:{{{zoom<includeonly>|</includeonly>}}}|zoom{{=}}{{{zoom}}}|}}|{{#if:{{{centro<includeonly>|</includeonly>}}}|center{{=}}{{{centro}}}|}}}}

Thanks FellTiger :) Really appreciate your help.