simplemaps

Add US territories | Documentation

While the United States is composed of 50 states, it also includes a few U.S. territories and commonwealths.  Some of these, such as Puerto Rico are very well known and have even considered becoming a U.S. state.  Others are smaller and less well known, such as the Northern Mariana Islands.  However, if you are displaying statistics or happen to do business in one of these locations (travel businesses), then you may want to include them in your interactive map.  While our JavaScript us map does not show these locations by default, they are included in the map and can be made visible by a simple edit to the mapdata.js file.  The following locations are available:

To add one, or more, of these islands to the map,  go to the end of the state_specific section of your mapdata.js file.  You will see the following:

GU: { name: 'Guam', description: 'default', color: 'default', hover_color: 'default', url: 'default', hide: 'yes' }, VI: { name: 'Virgin Islands', description: 'default', color: 'default', hover_color: 'default', url: 'default', hide: 'yes' }, PR: { name: 'Puerto Rico', description: 'default', color: 'default', hover_color: 'default', url: 'default', hide: 'yes' }, MP: { name: 'Northern Mariana Islands', description: 'default', color: 'default', hover_color: 'default', url: 'default', hide: 'yes' }

Simply replace hide: 'yes' with hide: 'no' and that territory will appear in your interactive map. This hide attribute actually works for all states. So, if you don't like Alaska and Hawaii hanging around in Mexico, you can add hide: 'yes' as a property to AK and HI and both states will disappear from the interactive map.

Please note that latitude and longitude markers do not work correctly with territories.  Also, if you need to show a U.S. territory that we have not included, please get in touch with us.

HTML5 Map Documentation v3.2

The current version is 3.2. Older docs: 3.0, 2.9
Already a customer and need to update?

Customization

Installation

Common Questions

Troubleshooting

JavaScript API

© Simplemaps.com 2010-2015 | License | Privacy Policy | Releases | Testimonials | Resources | Documentation
Deprecated Maps: Flash USA Map | Flash World Map | Flash Canada Map | Flash Europe Map | Flash Congress Map
Formerly FlashUSAmap.com and Flashworldmap.com