admin管理员组

文章数量:1389768

I would like to create a interactive geo map. I have already created world map as

region: 'world',
displayMode: 'regions'

And also created a map for india as markers

region: 'IN',
domain: 'IN',
displayMode: 'markers',

Now I need to create a map for india as regions instead of markers.
Now here is the problem with markers:-

I have successfully created it but there are some states which missing in that like uttarakhand, chhatisgarh and telangana. Can anyone help with that, here is the link to jsfiddle which is showing the map for indian states fiddle for map

I would like to create a interactive geo map. I have already created world map as

region: 'world',
displayMode: 'regions'

And also created a map for india as markers

region: 'IN',
domain: 'IN',
displayMode: 'markers',

Now I need to create a map for india as regions instead of markers.
Now here is the problem with markers:-

I have successfully created it but there are some states which missing in that like uttarakhand, chhatisgarh and telangana. Can anyone help with that, here is the link to jsfiddle which is showing the map for indian states fiddle for map

Share Improve this question edited Oct 15, 2016 at 6:32 Rahul K P 16.1k4 gold badges38 silver badges54 bronze badges asked Jun 28, 2016 at 10:21 Rakesh ChandRakesh Chand 3,1131 gold badge24 silver badges43 bronze badges 1
  • 1 @Mikel Is it possible to view districts in a state using this, specifically for Indian states? – S_S Commented Aug 16, 2017 at 9:06
Add a ment  | 

1 Answer 1

Reset to default 6

The map works, but some names can be wrong. I remend you to use the ISO codes to avoid those problems: https://en.wikipedia/wiki/ISO_3166-2:IN

You can create the data in this way:

  var data = google.visualization.arrayToDataTable([
    ['State Code', 'State', 'Population'],
    ['IN-UT', 'Uttarakhand', 10116752],
    //rest of states
  ]);

Fiddle

Tell me if it helps you.

本文标签: javascriptIndia states map in Google geomapsStack Overflow