添加多个地址编程到谷歌地图 [英] Add several addresses programatically into a google map

查看:124
本文介绍了添加多个地址编程到谷歌地图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个ASP.NET MVC应用程序4

I have a ASP.NET MVC 4 application.

让我们说我有从我的分贝,有一个场地址4的记录。

Let's say I have 4 records from my db that has a field address.

问:如何可以发送该地址到谷歌地​​图的控制(或直接到maps.google.com网站)?

Q: How can I send this addresses to a google maps control(or directly to the maps.google.com website) ?

推荐答案

使用第一ADRESS为 SADDR -parameter(起始地址)和其他3,分离 +为: DADDR -parameter(目的地址)

Use the first adress as saddr-parameter(start-address) and the other 3, separated by +to: as daddr-parameter(destination-address)

<一个href=\"http://maps.google.com/maps?saddr=strasbourg,france&daddr=troyes,france%20to%3aparis,france%20to%3anantes,france\" rel=\"nofollow\">http://maps.google.com/maps?saddr=strasbourg,france&daddr=troyes,france+to:paris,france+to:nantes,france

参数说明:http://www.seomoz.org/ugc/everything-you-never-wanted-to-know-about-google-maps-parameters

这篇关于添加多个地址编程到谷歌地图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆