使用带标记的 openstreet 地图和带 javascript 的折线
伙计们,我是使用 openstreetmaps 的新手。我知道如何使用 google 和 bing 地图 api。 我的要求是创建一个示例地图,其中仅包含一些标记来在它们之间定位和绘制多边形线。我已阅读 API,但找不到它如何使用。这是在商业应用程序中使用的。我需要指针和示例代码。请帮帮我。
Guys i am complete newbie in using openstreetmaps .i know how to use google and bing maps api.
my requirement is to create a sample map with just some markers to locate and draw poly lines between them.i have read the api but couldnt find it how to use.this is used in a commercial application.i need pointers and sample code.please help me out.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
查看任一 openlayers(OSM 在其页面上使用的内容):
http://dev .openlayers.org/releases/OpenLayers-2.10/examples/
或 Cloudmades new http://leaflet.cloudmade.com/ api
这两个都可以显示开放的街道地图数据
take a look at either openlayers (what OSM use on their pages):
http://dev.openlayers.org/releases/OpenLayers-2.10/examples/
Or Cloudmades new http://leaflet.cloudmade.com/ api
both of these can show open street map data
我已经做到了。您可以使用 openstreetmap.org 轻松完成此操作,使用以下 API
http://leaflet.cloudmade.com/index.html
I have done this. you can do it very easily with openstreetmap.org , Use this following API
http://leaflet.cloudmade.com/index.html
我建议您使用预渲染的 KML 输入文件。此示例向您展示如何在 OSM 上执行此操作:
http://maps.burningsilicon.net
放置一个指向您的底部文本框上的 KML 文件。
如果您想从 MySQL 数据库(或 csv 样式文本文件)动态创建文件,您可能需要查看 PHP KML 解析器示例。
i recommend that you use a pre-rendered KML input file. this example shows you how to do that on OSM:
http://maps.burningsilicon.net
place a link to your KML file on the bottom textbox.
you might want to check out PHP KML parser examples, if you want to create files on the fly from a MySQL database (or from a csv-style textfile).