WordPress.org

Ready to get started?Download WordPress

Plugin Directory

Placemarks

Allow authors to easily manage placemarks and embed custom maps.

What can the shortcode do?

[placemarks types="type name" lat=# lng =# zoom=# width="" height="" alt=true/false]

Everything after placemark is optional:

  • types: String. List of types to include on the map "default, foo bar" (shows all by default)
  • lat: Number. Use lat+lng+zoom to choose an initial map view (defaults to show all pins)
  • lng: Number. Use lat+lng+zoom to choose an initial map view (defaults to show all pins)
  • zoom: Number. Use lat+lng+zoom to choose an initial map view (defaults to show all pins)
  • width: String. Change the width of the map (default '100%')
  • height: String. Change the height of the map (default '400px')
  • alt: True/False. A text list of all the markers shows under th map by default. This can be used to turn it off.

How do I edit the locations and types drop-downs?

Go to Settings -> Placemarks. Here you can use JSON to create custom lists. For example:

Marker Types (JSON): name and src are required

{ "types": [
    {"name":"Default", "src":"http://www.yoursite.com/default.png"},
    {"name":"Hot", "src":"http://www.yoursite.com/hot.png"}
    ]
}

Locations (JSON): name and slug are required. slug should always be unique

{"locations": [
    {"name":"Oregon","slug":"or"},
    {"name":"Washington","slug":"wa"}
    ]
}

Optionally, you can also include: lat, lng, zoom. Together, these control the map when selected in the admin interface.

{"locations": [
    {"name":"Oregon","slug":"or","lat":45.563282,"lng":-122.673457,"zoom":17},
    {"name":"Washington","slug":"wa","lat":45.563838,"lng":-122.672342,"zoom":19}
    ]
}

Each location can also include locations. This can be used to create hierarchies of select lists!

{"locations": [
    {"name":"Oregon","slug":"or", "locations":[
        {"name":"Portland","slug":"pdx"},
        {"name":"Bend","slug":"bend"}
        ]
    },
    {"name":"Washington","slug":"wa", "locations":[
        {"name":"Seattle","slug":"sea"}
        ]
    }
    ]
}

Requires: 3.0 or higher
Compatible up to: 3.7.1
Last Updated: 2013-11-20
Downloads: 298

Ratings

5 stars
5 out of 5 stars

Support

Got something to say? Need help?

Compatibility

+
=
Not enough data

0 people say it works.
0 people say it's broken.

100,1,1
100,1,1