我使用google地图API来跟踪两点之间的路线,我的代码是:
NSString *urlString = [NSString stringWithFormat:@"https://maps.google.com/maps?saddr=%f,%f&daddr=%f,%f&hl=fr&output=embed&om=5",latUtilisateur,longUtilisateur,latStation,longStation];
//Create a URL object.
NSURL *url = [NSURL URLWithString:urlString];
//URL Requst Object
NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
//Load the request in the UIWebView.
[webView loadRequest:requestObj];但是,这没有文本说明功能。我是不是在上面的请求中遗漏了一些参数或其他什么?
发布于 2011-06-28 19:41:56
output=embed参数将生成全屏地图。您可以尝试几个替代方案:
标准地图/方向页面的
http://maps.google.com/maps?saddr=Sydney&daddr=Brisbane&hl=fr&output=html&om=5
http://maps.google.com/maps?saddr=Sydney&daddr=Brisbane&hl=fr&output=mobile&om=5
https://stackoverflow.com/questions/6505234
复制相似问题