Introduction
When dealing with country data its useful to be able to highlight a country or a set of countries on a map. This module provides a field formatter which can display a single country highlighted on a map. It also integrates with Views which allows you to highlight your country based nodes as countries on a map.
About this module
This module provides:
- A new field type called leaflet_countries which allows a user to select a country
- Two field formatters for the new field type:
- A formatter which displays the country on a leaflet map
- A formatter which displays the three letter country code
Installation
Instructions are in the README.md. Composer is strongly recommended for installing the dependencies.
Dependencies
The module depends on the leaflet module and leaflet library to render the maps. There is also a dependency on the leaflet_topojson module which provides TopoJSON integration with the leaflet library. The dependencies are handled by composer when installing.
Usage
Instructions are in the README.md
Recommended modules
- Leaflet More Maps - Provides more maps for leaflet!
3rd party libraries and licensing
https://github.com/mledoze/countries - License
Credit
Thanks to the very useful library https://github.com/mledoze/countries which makes installing this much easier.
| Attachment | Size |
|---|---|
| Drupal View showing countries as overlays | 103.1 KB |
Project information
Minimally maintained
Maintainers monitor issues, but fast responses are not guaranteed.8 sites report using this module
- Created by tanc on , updated
Stable releases for this project are covered by the security advisory policy.
There are currently no supported stable releases.

