Interactive Map
The Interactive Map element embeds a map with markers on it. It is what most of the demos use on a contact page, and it can sit in any row like any other element. Above is the Google Map provider with Marker Style set to Nectar Animated.
Choosing a map provider
Map Type offers two, and the choice mostly comes down to whether you want to deal with an API key.
- Leaflet Recommended. Nothing to set up: it works as soon as you place the element.
- Google Map Needs a Google Maps API key, entered once in Salient Options > General Settings.
If you pick Google Map and the map renders blank or grey, a missing or restricted API key is almost always the cause. Google's own guide covers generating one.
Settings
Position
- Map Center Point Latitude and Map Center Point Longitude Where the map is centered. These are coordinates, not an address: right-click a spot in Google Maps and it will give you the pair.
- Map Zoom Choice How close in the map starts.
- Map height Number The height of the embed, in pixels.
Markers
- Map Marker Locations Text One marker per line, each with its own coordinates and the text shown when a visitor clicks it.
- Marker Style Choice Default Style for the standard pin, or Nectar Animated for a pulsing marker that draws the eye.
- Marker Color Choice The pin color, from the theme palette.
- Marker Image, Image Width and Image Height Replace the pin with your own graphic, a logo being the usual case.
Appearance
Greyscale Color is the gate for everything else here: the three settings below it only appear once it is on, because each one is a variation on the greyscale scheme rather than a separate look.
- Greyscale Color Toggle Drains the color out of the map. On Google Map it swaps in a styled color scheme; on Leaflet it is a filter over the tiles.
- Map Extra Color Color Puts one hue back into the greyscale map, so it can be brought closer to the site's palette rather than sitting on the page as a block of default map colors.
- Ultra Flat Map Toggle Removes street and landmark labels, transit lines and administrative boundaries, leaving the shapes on their own.
- Dark Color Scheme Toggle A set of greys with the roads drawn darker than the land and only the highway casings picked out lighter. Google Map only.
Setting Dark Color Scheme overrides Map Extra Color; the two cannot be combined. If you have picked an extra color and the map still renders grey, this is why.
A single marker centered on the map is the right treatment for a contact page. Multiple markers make sense for a store locator or a coverage map, in which case zoom out far enough that they all sit in view on load.