Map block

The LH Places Map block (lh-places/map, in the Embed category) draws geo-tagged posts on a Leaflet map. It is rendered on the server, works from any post type, and supports wide and full alignment. Each marker’s popup links to its post and shows its address.

SettingDefaultWhat it does
Post typepostOne or more post type slugs, comma-separated. Left blank, every post type is searched.
Post statuspublishOne or more statuses, comma-separated. Custom statuses work.
Posts10How many posts to plot.
CategorynoneCategory ID.
Post parentnoneOnly children of this post.
Specific postsnoneComma-separated post IDs.
Height400pxAny CSS height. The width always fills the container.
Zoom13The exact zoom for a single place. With several places the map first fits them all, and only zooms out further than this if it has to.
LayerstreetStarting layer, street or satellite. Viewers can switch between them.
Show numbered listonWith several places, numbers the markers and lists the posts below the map. The list works without JavaScript.

Street tiles come from OpenStreetMap and satellite tiles from Esri World Imagery, so no API key is needed. In the editor preview, a block that matches no posts shows a placeholder explaining why. On the public site it renders nothing.

The [lh_places_geomap] and [lh_places_geojson] shortcodes were removed in 1.24. Use this block, or the REST API for raw GeoJSON.