You can customize the appearance and behavior of the map by passing an options object to .vectorMap().
Key configuration options include:
map: The map to load (e.g., 'world_en').backgroundColor: CSS compatible background color.borderColor, borderOpacity, borderWidth: Styling for region outlines.color: Default color for map regions.colors: An object where keys are ISO 3166-1 alpha-2 country codes (lowercase) and values are colors.enableZoom: Boolean to enable/disable zoom (defaults to true).hoverColor, hoverOpacity: Styling for regions when hovered.scaleColors: An array of hex colors used for data visualization scaling.selectedColor, selectedRegions: Styling and pre-selection for regions.showTooltip, showLabels: Boolean to toggle tooltips or ISO labels.pins: An object mapping country codes to pin content.pinMode: Determines if pins contains HTML strings ('content') or DOM element IDs ('id').
jQuery('#vmap').vectorMap(
{
map: 'world_en',
backgroundColor: '#a5bfdd',
borderColor: '#818181',
borderOpacity: 0.25,
borderWidth: 1,
color: '#f4f3f0',
enableZoom: true,
hoverColor: '#c9dfaf',
hoverOpacity: null,
normalizeFunction: 'linear',
scaleColors: ['#b6d6ff', '#005ace'],
selectedColor: '#c9dfaf',
selectedRegions: null,
showTooltip: true,
onRegionClick: function(element, code, region)
{
var message = 'You clicked "'
+ region
+ '" which has the code: '
+ code.toUpperCase();
alert(message);
}
});