Android Question Accessing Google Maps API & Download vs. Download2

KMatle

Expert
Licensed User
Longtime User
Probably I'm blind, but

this works with Download only

B4X:
GetDirectionsJob.Download("https://maps.googleapis.com/maps/api/directions/json?origin=K%C3%B6ln&destination=Kerpen&key=AIzaxxxxxxxxx")

but doesn't with Download2 (Don't be irritated about the char ö)

B4X:
GetDirectionsJob.Download2("https://maps.googleapis.com/maps/api/geocode/json", _
              Array As String("origin","Köln","destination","Kerpen","key","AIzaxxxxxx"))

B4X:
   "error_message" : "Invalid request. Missing the 'address', 'bounds', 'components', 'latlng' or 'place_id' parameter.",

Any ideas? Never had such an issue. By the way: Can the generated get request be logged to see the format?
 

sorex

Expert
Licensed User
Longtime User
if it worked before on another site then you were just lucky as they checked all transfered content or used POST to retrieve the values..

here they apparently only check for url based GET values and not POST.

this is how they pull the values in their backend.
 
Upvote 0
Top