Google Maps Directions in XML or JSON with other travel modes - ios

I'm trying to get the directions for travel modes other than driving but the api doesn't seem to respect the dirflg parameter.
http://maps.googleapis.com/maps/api/directions/json?origin=111%20Davisville%20Avenue,Toronto,ON&destination=469%20King%20Street%20West,%20Toronto,%20ON&sensor=false&dirflg=w
Can anyone tell me what the correct url is? Thank you in advance.

the parameter is mode, as in mode=walking:
http://maps.googleapis.com/maps/api/directions/json?origin=111%20Davisville%20Avenue,Toronto,ON&destination=469%20King%20Street%20West,%20Toronto,%20ON&sensor=false&mode=walking

Related

Google Place Api, Find Place From Text not working

I've been trying to use the google place api to get the shops inside a specified range from my coordinates and street adress as parameter, but not lucky.
Would be possible to someone tell me what if I may be sending the request with the wrong parameters?
https://maps.googleapis.com/maps/api/place/findplacefromtext/json?input=wickham%20street&inputtype=textquery&fields=photos,formatted_address,name,opening_hours,rating&locationbias=circle:500#-27.4554492,153.0334623&key=[APIKEY]
Thank you

Get Popular Locations close by - Google Maps/Places SDK for iOS

I'm investigating how and if there is a way to get a list of popular locations near you (or within an area) using the Google Maps/Places API. Please see the attached screenshot for what I am referring to:
You'll notice the "Popular Locations in Toronto, On" section. Is there a way to get a list of these by passing in your current location, whether that be with coordinates or simply an address? I'm trying to understand how this was achieved in the above screenshot. Any help would be greatly appreciated. Thanks in advance!
You can use this web service api
https://maps.googleapis.com/maps/api/place/nearbysearch/json?location=(latitude),(longitude)&radius=5000&key=(api_key)
to get all the nearby places. It also contains mechanisms to filter, keyword, etc.
You can check out this link https://developers.google.com/places/web-service/search to see a list of required and optional parameters that you can pass additionally.
In case you want to use native iOS sdk https://developers.google.com/places/ios-api/start this is a good place to start.

UTM Not Working

We are currently using a number of UTM codes with various companies to track a campaigns to our website. While most of them have worked without issue, three have failed to be recorded by Google Analytics and they all use the same format (two of the URLs are below). Any idea why this would be? The links themselves work, it's just GA hasn't accepted them at all.
https://urldefense.proofpoint.com/v2/url?u=http-3A__www.semble.co.nz_mobilepay_bnz_-3Futm-5Fsource-3Dbnz-5Fapp-26utm-5Fmedium-3Donline-5Fbanner-26utm-5Fcontent-3Durl-5Fappnotification-26utm-5Fcampaign-3Dmobilepay-5Fcampaign&d=CwMFAg&c=N-xPqDyeLJg5V3gLll2thA&r=lbXMFujwGwA66Ivf0fYOaY8Dv5vHXIMr8z9PppNbh6c&m=JP3JnHYmkJ3J1YBwv9iHgnMsJJZdyrflVUuPxw_okaA&s=xT3UnMPmiP-DJPNwtQhywHsRWvmMg7PMylFMQjrGov4&e=
https://urldefense.proofpoint.com/v2/url?u=http-3A__www.semble.co.nz_mobilepay_bnz_-3Futm-5Fsource-3Dbnz-5Fapp-26utm-5Fmedium-3Dgoogle-26utm-5Fcontent-3Durl-5Fappnotification-26utm-5Fcampaign-3Dmobilepay-5Fcampaign&d=CwMFAg&c=N-xPqDyeLJg5V3gLll2thA&r=lbXMFujwGwA66Ivf0fYOaY8Dv5vHXIMr8z9PppNbh6c&m=JP3JnHYmkJ3J1YBwv9iHgnMsJJZdyrflVUuPxw_okaA&s=wN-S93ZKKnjHZoGSPZJCTTvDk9NeqUd7zG9W5MoGwKA&e=
Thanks in advance!
You URL is not correctly builded, you must found any of this strings on your URL :
&utm-campaign=
&utm-source=
&utm-medium=
And didn't appear, seems like your system are recoding URL in some point.

Can we find which direction we are travelling with respective to the path (Polyline points path)?

I am implementing tracking application using Google maps SDK in IOS
i want to know whether we can track the user moving forward or reverse direction on the Polyline path and identify if user travels reverse direction
Please provide any valuable suggestions.
Thanks in advance
You can use GoogleMapsDirection to get the path or DirectionResponse from the Google Directions API.

http://m.bing.com/directions parameters?

Hi all I need to know on how to pass two points (longitude and latitude) in http://m.bing.com/directions? to draw a route and show driving directions to the user.
I had find a solution by trial and error in this is the resulting URL: http://m.bing.com/directions?IIG=acc63aafc7ac4348b2fa7662d871504a&kval=3.1&appns=mSERP&cutc=1362555191520#/Maps?q=37.332333,-122.031219,,,,current%20location~42.983391,-81.233040,,,,current%20location&ul=&mode=1&autoredirect=0
I'm passing this from my app to safari mobile.
I need to know a proper way of passing two point and also if there are other parameters if there are any.
I googled for many hours and nothing is resolved.
Thanks!
you might be able to use the same parameters than with the bing maps portal, see the documentation here and if the user is using a mobile platform, he should be redirected to the mobile version:
http://onlinehelp.microsoft.com/en-us/bing/ff808440.aspx
Here is also an interesting article from Alastair on his blog:
http://alastaira.wordpress.com/2012/06/19/url-parameters-for-the-bing-maps-website/

Resources