Link to street view URL using address?

google-maps google-street-view

3948 просмотра

2 ответа

235 Репутация автора

Is it possible to link directly to street view from an URL using only the address (and not lat/lng)?

For example, is there a way to do something like,number,state&cbp=11,0,0,0,0

Instead of,-89.287204&cbp=11,0,0,0,0


Lat/lng from geocoding tends to not be recognized by street view as being too far from a street, sometimes getting the wrong street altogether, because the lat/lng it generates may be off the street, as it tries to match the location of a house.

I have looked everywhere and even tried playing with google's URLs on my own, but I can't find anything on it. Most sources won't even mention address. I'm currently using the url sample from this question, but it still isn't really what I'm looking for.

If this is really not possible, could someone link to a source/documentation where it says so?

Edit: Thank you everyone for the answers, but none really address the issue with street view and addresses. I'll look into forwarding this to google. I'll post here if I get a reply.

Автор: Forty Источник Размещён: 17.07.2016 11:20

Ответы (2)

1 плюс

8587 Репутация автора

First reverse geocode to find the lat lng using another Google Service API.

Then feed the resulting lat lng into the streetview endpoint parameter.

Автор: ina Размещён: 18.07.2016 06:42

1 плюс

494 Репутация автора

Let's enhance your code, if you paste the code in browser then you will be redirect to google maps and will show result what you requested.,Seattle+WA

If you would like to pass the value (address) via php or any other code type then simply it will not work, you cannot use google maps without API to enhance your requirement. Lat & Lng is basic practice to show map and not require any api, but if you would like to pass additional properties then you will have to use google maps api to do so. Detailed documentation can be found here

but let's try an example try this code in browser,+Maharashtra,+India

You will get an error that api key not found but if you try this one,Seattle+WA

Then you will get output. Hope it helps!

Автор: Sachin G. Размещён: 30.07.2016 08:39
Вопросы из категории :