0

I want to query the Google map for all the roads leading to a given GPS coordinate.

For that I'll have to place a "query" which can be done by: http://doc.qt.io/qt-4.8/qurl.html#addQueryItem

Now I want to know how to figure out that what should be the key and its corresponding value here?

Should the key be "road"/"roads"? Whats the way to decide that? And I want all the roads not a particular one!

Any hints?

Christophe Weis
  • 2,518
  • 4
  • 28
  • 32
Aquarius_Girl
  • 21,790
  • 65
  • 230
  • 411

1 Answers1

4

An HTTP URL has the following format: http://some/address?key=value&more=values

The part behind the '?' is your query. You have to determine how the resulting URL should look like and add key/value pairs accordingly.

It isn't completely clear to me what you want to accomplish. You might want to check out these Google Maps API Links:

thammi
  • 444
  • 1
  • 4
  • 17
  • Thanks for answering, now, for example the url: http://maps.google.co.in/maps?hl=en&xhr=t&q=map+of+india&cp=7&um=1&ie=UTF-8&hq=&hnear=0x30635ff06b92b791:0xd78c4fa1854213a6,India&gl=in&ei=KsLQTcPZEuXq0gGbqoGVCw&sa=X&oi=geocode_result&ct=image&resnum=1&sqi=2&ved=0CCwQ8gEwAA . If you look at the first words after the "?", they are: _hl=en_. How to know what is hl here and what is en? What do they return? – Aquarius_Girl May 16 '11 at 06:23
  • and secondly, I want to accomplish this through Qt API instead of Google API. – Aquarius_Girl May 16 '11 at 06:31
  • 1
    The key/value pairs in the query string are defined by the website you are using. You therefore have to read the Google API documentation to find out which parameter means what. – thammi May 16 '11 at 07:30
  • Thanks thammi, after reading your last comment, I found this: http://mapki.com/wiki/Google_Map_Parameters Perhaps, this is what I needed :) – Aquarius_Girl May 16 '11 at 07:44