mapstraction

Upgrading google maps api with mapstraction in Rails 3

試著忘記壹切 提交于 2020-01-17 04:45:06
问题 I'm trying to upgrade an app into Rails 3. The app requires a map that can be edited and it has been using google maps and mapstraction. When I upgraded to rails 3 the map stopped showing up and I figured that's because it needed to be updated from google maps api v2 to v3. I've been trying to use this tutorial to upgrade it but because the app is using mapstraction I've been having difficulty getting it to work. Initially, this was in the html: <script src="http://maps.google.com/maps?file

Mapstraction - draw polygon dynamically

喜夏-厌秋 提交于 2019-12-13 01:43:41
问题 In Mapstraction map need to draw a polygon which is editable. So i have tried a example. But polygon is editable mode while it's calling function href="javascript:mapstraction.activateEdition();" in example. I have tried to do that. Didn't get succeed. How do i create polygon which user can edit it and also is this possible to keep only 10 vertices polygon. JS Code var polyPoint; var polyPoints = [] //Adding polygon to map polyPoint = new mxn.LatLonPoint(17.447612 , 78.223686) polyPoints.push