Encoding URL by Google static maps - google-maps

I created the URL for static maps, everything works, but now convert this link you can open the map in Google?That is on my website there is a picture card, but in the form of links, similar to here. How now add a link to this image, so when you click on the image to the full Google maps?
Advance, thanks!

Maybe this (if I understood you) - depending on what is in .$full_address.:
<img src="http://maps.googleapis.com/maps/api/staticmap?center=".$full_address."&zoom=15&size=400x400".$markers."&sensor=false' />">
This will turn your static map image into a link to Google Maps.

Related

Mark a place on Google Map and embed widget

http://snag.gy/mHDah.jpg
Please look at the above picture.
I want to add a place to the map and export embed html widget to my web site.
But the problem is a place is not there. (Not body added that place to Google Map).
I want to mark that place with a red point in a embed map. (Please look at the below snapshot)
http://snag.gy/7DFm3.jpg
Please help me.
Maps Engine Lite (Beta) is a tool which allows you to design and save your own custom maps. In order to make use of it, you'll need to have a Google account and be logged in.
For example, have you tried to embed a newer Google map into a web
page? The reliable old "link" button is nowhere to be found!
A simple example is here
Those pins are called markers in the gmaps API.
This example does what you want: https://developers.google.com/maps/documentation/javascript/examples/marker-simple
You can use normal Google maps to find out the coordinates for your place by right-clicking on it and choosing "what's here" (works in chrome and safari at least).

Link to Google Maps

I'm developing a website in HTML and I would like to surround a postcode with a link so that when a user clicks on the postcode he is sent to google maps searching that postcode. Any advice how can I do that? Thanks!
POSTCODE
You mean like that?
See the Map Images API on Google. It's actually pretty straight forward.
Static Maps API
Add static maps, including terrain or satellite maps, to your web page or application. The Static Maps API supports custom styling, high resolution printing and displays, markers, and geometry.
Read the developer documentation.
<img src="http://maps.googleapis.com/maps/api/staticmap?center=-15.800513,-47.91378&zoom=11&size=200x200&sensor=false">
Dev Documentation is here: https://developers.google.com/maps/documentation/staticmaps/index
Just put this type of link with q=postcode :
Go on maps
example
Go on maps
Enjoy

Custom Marker Icon not showing Google Static Maps v2

I am using the Static Google Maps API v2 to download a static image of a map view with a singular marker just showing one image. However, the image added to the marker parameter of the url doesn't seem to be making any difference, and just a red marker is shown at the location.
Please can you tell me where I am going wrong?
http://maps.googleapis.com/maps/api/staticmap
?center=37.446754,-77.572746
&size=70x61
&maptype=roadmap
&sensor=true
&scale=2
&zoom=15
&key=some_key
&markers=icon:https://foursquare.com/img/categories_v2/shops/financial_bg_64.png|37.446754,-77.572746
your image URL must remove the letter S HTTPS secure site, so work, for example like this:
http://foursquare.com/img/categories_v2/shops/financial_bg_64.png
complete code:
http://maps.googleapis.com/maps/api/staticmap?
center=37.446754,-77.572746&size=70x61&maptype=roadmap&sensor=false
&scale=2&zoom=15
&markers=icon:http://foursquare.com/img/categories_v2/shops/financial_bg_64.png|37.446754,-77.572746
In my experience,
There is no such requirement of http or https just care for icon size .
icon size should not exceed more than 64X64 pixels in size , Static map will happily show the custom icon . accept if found correct #max_
http://maps.googleapis.com/maps/api/staticmap?
center=37.446754,-77.572746&size=70x61&maptype=roadmap&sensor=false
&scale=2&zoom=15
&markers=icon:http://foursquare.com/img/categories_v2/shops/financial_64X64.png|37.446754,-77.572746
off course use your image with below 64X64 dimension instead of
http://foursquare.com/img/categories_v2/shops/financial_64X64.png
You're actually not doing anything wrong, it's Google to blame:
"The Google Static Maps API does not support custom icon URLs that use HTTPS"

Embeded google street view

Is it possible to have a google map embeded street view panorama of a given address in your page?
All the codes I have came across work with coordination, I'm looking for "address", since if you just use coordination you will have to set pov and all that,
Google seems to do that itself, look at the panorama picture here:
http://maps.google.ca/maps/place?hl=en&sugexp=kjrmc&cp=10&gs_id=z&xhr=t&biw=1680&bih=874&gs_upl=&bav=on.2,or.r_gc.r_pw.,cf.osb&um=1&ie=UTF-8&q=toyota+calgary&fb=1&gl=ca&hq=toyota&hnear=0x537170039f843fd5:0x266d3bb1b652b63a,Calgary,+AB&cid=16440335169618939517&ei=VpqYTpPsLbCrsALi0LnqBA&sa=X&oi=local_result&ct=map-marker-link&resnum=1&sqi=2&ved=0CF8QrwswAA
Thanks
Yes, using the Google Maps Javascript API V3. Take a look here: http://code.google.com/apis/maps/documentation/javascript/services.html#StreetView
You can also embed Street View on your page by just using Google Maps.
Search for the address on Google Maps.
Go to the Street View for the location.
Click the link button in the upper-right hand corner above the map.
Click the 'Customize and preview embedded map' link.
A new page will open up with some customization opens and the code to embed the map/image on your page.
Yes you can. All you need is a google decoder who will decode your address. Another way is to directly pass your address as a part of the url to google.
When using decoder, you will get the result in the form of a latitude longitude object which you can use to reset/set your map's marker
There is no way to accurately set the heading automatically and no way to set the pitch and fov (field of view) - BUT if you figure these out manually you can create a URL that fetches a static image with those settings from Google
Take a look at this tutorial on the Street View Image API

Custom placemarks directly on maps.google.com for my map

I made a custom map with a couple of placemarks on it. I have copied html code and pasted it into my web page. Everything works fine. The map and placemarks are displayed correctly.
And when I press the bottom left corner button "Click to see this area on Google Maps" I can see my map directly on maps.google.com but the placemarks disappear.
Is it possible to show the placemarks on my map right on the maps.google.com? or can I manage placemarks for my custom map directly on maps.google.com using API?
I think the closest thing to what you are after is MyMaps. My maps lets you create map content ( or import KML, KMZ, or GeoRSS files), on maps.google.com. I think you can programaticaly create maps via the Google Data API.
I am not sure what your requirement is, but if your content is static you could create a MyMap up front and then load that url rather than maps.google.com.
Here is the example of what i need -)
We send request to maps.google.com to show some area (sending latitude, longtitude, zoom) and then we specify the placemarks we want, not by hand (using MyMaps) but using API. And we need to do it directly on the maps.google.com, not on my own site or home page with embeded or even programm builded map.
Thanks to Cannonade. The links you've shared helps me a lot -)