问题描述
以下是我正在努力做的事:
在页面上显示地图(谷歌地图或任何竞争对手,免费是可能的...),并突出显示该地图上的某些国家(这些国家的名单
我尝试在地图上绘制多边形,其中包含(几乎)所有国家/地区的地理位置列表,但它太重。
有什么想法?
我相信你会需要一个多边形来做到这一点。最后,还有Google Geochart
请点击此处:
Here's what I'm struggling to do :Display a map on page (Google map or any of it competitors, free is possible...) and highlight certain countries on this map (the list of theses countries would be stored in a variable by exemple).
I tried to draw polygons on the map with a geo-json list of (almost) all the countries but it's too heavy.
Any ideas ?
I believe you will need a polygon to do that.
http://code.google.com/apis/maps/documentation/overlays.html#Polygons_Overview
http://code.google.com/apis/maps/documentation/reference.html#GPolygon
like this sample: http://gmaps-samples-v3.googlecode.com/svn/trunk/poly/pentagon.html
Or check this site that can do all the hard work for you :)
http://www.dyngeometry.com/web/WorldRegion.aspx
Finally, there is also Google Geochart
Check it here: https://developers.google.com/chart/interactive/docs/gallery/geochart
这篇关于显示地图并突出显示某些国家/地区的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!