Map Shortcode Parameters & Map Mashup at WPGMAPS plugin documentation

Map Shortcode Parameters

Regular Usage

To add the map to a page on your site you will need to add the following shortcode to that page:

[ wpgmza id=”1” ]

This will allow you to display the map that has the ID of 1 on your page. You are able to see what map you are working on by going to the Maps page and then selecting the map to place on the site, the shortcode is automatically generated for you:

Map Shortcode

Map Mashup

If you would like to join multiple maps into one map, simply use the following customized shortcode and shortcode attributes:

[ wpgmza id="1" mashup=true mashup_ids="1,2,3,4" parent_id="1" ]

Below are some key points to consider:

id = main ID. This MUST be the same as the parent_id – so in the example above “1”

mashup = Set as true to indicate you that you would like this map to be a mashup

mashup_ids = Include all the ID’s you would like to Mashup but separate them by commas

parent_id = Setting this to a specific map ID will use the settings of that particular map as the settings for the mashup map – so whatever color or size is set for map ID 1 will be used for the map

With the code above you are able to display two or more maps on one page with ease.

You will need to ensure that you have correct map ID’s in the Mashup otherwise it will not work.

Category Usage

There may be a time where you only want to display a certain category of markers on your map. If you wish to do this, you will need to first make sure that the category exists and that the ID is correct.

To do this, you will need to go to the Category page in the Maps menu. You can then create a new category or you can see the ID’s of your existing ones.

Category Observe

You can then add the following code to your page with the required category ID:

[ wpgmza id=’1′ cat=’6’ ]

With this shortcode above, only the markers that have been marked as ‘Water Parks’ will be displayed on the map.

Map Mashup

If you would like to join multiple maps into one map, simply use the following customised shortcode:

[ wpgmza id="1" mashup=true mashup_ids="1,2" parent_id="1" ]

(remove the first and last space between the square brackets)

Where:

id = main ID. This MUST be the same as the parent_id

mashup = set as true to indicate you that you would like this map to be a mashup

mashup_ids = Include all the ID’s you would like to mashup separated by commas

parent_id = Setting this to a specific map ID will use the settings of that particular map as the settings for the mashup map.

1

No Responses

Write a response