Shortcode


To display the nearby palces map in your page, copy/paste the shortcode [cs_nearby_map] in your page.

The settings of this map can be set from the menus (Progress Map / Default map settings), (Progress Map / Default map style settings) & (Progress Map / Default infobox settings)!

The shortcode supports the following attributes:


post_ids (optional)

The ID of the post to display on the map. If no ID was provided, the map will use the ID of the current post displayed.

Example: [cs_nearby_map post_ids="1"]


map_id

A string name that represent the unique ID of the map. This attribute is only required if the attribute geoloc is set to yes.

Please don’t use the same ID for two maps displayed on the same page. This will create unexpected conflicts between the maps!

Example: [cs_nearby_map map_id="map25"]


center_at (optional)

The center point of the map. By default, the map center will be the position of the current post or the post specified with the post_ids attribute. To override the map center point, enter the Latitude and Longitude of the new center point, or enter the ID of another post to center the map on that location.

Example 1 (latLng coordinates): [cs_nearby_map center_at="51.510879,-0.117813"]

Example 2 (Another post ID): [cs_nearby_map center_at="10"]


distance_unit

The unit system to use when displaying distance. Possible values are METRIC and IMPERIAL.

Example: [cs_nearby_map distance_unit="IMPERIAL"]


radius

The distance from the given location within which to search for Places, in meters. Possible value is a number from 1 to 50000 maximum.

Example: [cs_nearby_map radius="2500"]


geoloc

Whether to use the map to detect the user’s location and a given address, or, to use it with a post. Possible values are yes and no. Default to no.

Example: [cs_nearby_map geoloc="yes"]


places

The list of place types to enable. Separated by comma (,).

Find the list of all available places in the plugin settings page under the field “General settings / Place types”.

Example: [cs_nearby_map places="school,hospital"]


layout

Display layout. Possible values are pl-mr , ml-pr and pt-mb.

  • pl-mr Places Left, Map Right
  • pr-ml Map Left, Places Right
  • pt-mb Places Top, Map Bottom

Example: [cs_nearby_map layout="pr-ml"]


list_grid

The number of place types to display in a single row. Possible values are 2cols, 3cols, 4cols and 6cols.

Example: [cs_nearby_map list_grid="4cols"]


height

The height of the map in pixels.

Example: [cs_nearby_map height="500px"]


width

The width of the map. For example, 600px or 100%.

Example 1: [cs_nearby_map width="100%"]

Example 2: [cs_nearby_map width="600px]


map_style

The skin of the map. To get the style name, follow these steps:

  1. Click on the menu “Progress Map”. Wait for the page to load!
  2. Click on the menu “Default Map style settings”
  3. Select the option “Progress Map styles” in the field “Style option”
  4. Click the link “Demo” next to the style you like. A new page/window will open, the URL of that page/window holds the style name as the last attribute. So if the URL looks like http://snazzymaps.com/style/42/apple-maps-esque, the style name will be apple-maps-esque.

Example: [cs_nearby_map map_style="apple-maps-esque"]


initial_map_style

The initial style of the map. Possible values are ROADMAP, SATELLITE, TERRAIN, HYBRID, custom_style.

Example: [cs_nearby_map initial_map_style="SATELLITE"]


zoom

The zoom of the map. From 0 to 19. Default to 13.

Example: [cs_nearby_map zoom="6"]


show_overlay

Show/Hide the marker overlays (infobox). Possible values are yes and no.

Infoboxes are not used when geoloc is set to yes!

Example: [cs_nearby_map show_overlay="no"]


infobox_type

The infobox type. Possible values are, square_bubble, rounded_bubble, cspm_type1, cspm_type2, cspm_type3 and cspm_type4.

Example: [cs_nearby_map infobox_type="cspm_type3"]


infobox_link_target

Defines the target of the infobox link. Possible value, “same_window”, “new_window” & “disable”.

Example: [cs_nearby_map infobox_link_target="new_window"]