Welcome to the new home of the Cumulus Support forum.

Latest Cumulus release v1.9.4 (build 1099) - Nov 28 2014
Latest Cumulus MX release - v3.0.0 build 3043 Jan 20 2017. See the Wiki for download

Google map message on website

Other discussion about creating web sites for Cumulus that doesn't have a specific subforum

Moderators: daj, TNETWeather

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 8:33 am

For almost 10 years I've embedded a small Google map on my website showing my location. It was fine until this morning. It's now displaying a message saying "This page can't load Google Maps correctly. Do you own this website?"

I click OK and the message is removed but although the map is still visible it's changed to grey and looks pretty unattractive.

Have Google changed their policy about use of their maps for private non-profit making use?
Cheers,
Ray, Cheshire.

Image

User avatar
steve
Cumulus Author
Posts: 26714
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Google map message on website

Post by steve » Wed 22 Aug 2018 9:14 am

I think Google now require you to obtain an API key - f you click on 'do you own this web site' you get more information. The Cumulus user map has the same issue. Not sure whether it's still free, I have yet to investigate.
Steve

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 9:18 am

Hi Steve. I didn’t see anything asking for more info. If you find a solution I’d appreciate knowing what I need to do.
Cheers,
Ray, Cheshire.

Image

User avatar
ConligWX
Posts: 728
Joined: Mon 19 May 2014 10:45 pm
Weather Station: Davis Vantage Pro2 Plus
Operating System: Debian 9.5 Stretch
Location: Bangor, NI
Contact:

Re: Google map message on website

Post by ConligWX » Wed 22 Aug 2018 9:20 am

steve wrote:I think Google now require you to obtain an API key - f you click on 'do you own this web site' you get more information. The Cumulus user map has the same issue. Not sure whether it's still free, I have yet to investigate.
afaik the api maybe free but they will eventually charge you for the service. Thats why Ken True and others have moved away from Google maps to Openstreetmap/leafletjs scripts for their templates.

More info here: https://cloud.google.com/maps-platform/user-guide/
Last edited by ConligWX on Wed 22 Aug 2018 9:26 am, edited 1 time in total.
Regards Simon

https://www.conligwx.org
https://twitter.com/conligwx
Davis Vantage Pro2 Plus - CumulusMX v3.0.0 (build 3043) + Saratoga/PWS Templates

User avatar
steve
Cumulus Author
Posts: 26714
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Google map message on website

Post by steve » Wed 22 Aug 2018 9:21 am

Looks like everyone now pays, but you get $200 free credit every month. Haven't yet worked out what you get for that (despite having looked at a table which supposedly explains it!).
Steve

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 9:25 am

If there’s a charge applied each time someone visits the page that could be troublesome. OpenStreetMap seems a reasonable alternative but I’ll wait until Steve has investigated fully.
Cheers,
Ray, Cheshire.

Image

User avatar
mcrossley
Posts: 5209
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Google map message on website

Post by mcrossley » Wed 22 Aug 2018 9:29 am

AFAIK, if you embed a map and places markers on it, but do not use the Directions mode, Street View mode, or Search mode - then it is still free with unlimited usage.

The $200 credit goes against usage of those 'advanced' features.

Edit: I've disabled Street View, and full screen mode on my embedded map to prevent the possibility of being charged - you can set a charge limit on the key as well.

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 9:38 am

Thanks Mark. Mine has a place marker. Not sure about Street View. Given the size of the map I’ve not used that option. I assume there is a way of controlling these options.
Cheers,
Ray, Cheshire.

Image

User avatar
mcrossley
Posts: 5209
Joined: Thu 07 Jan 2010 9:44 pm
Weather Station: Davis VP2
Operating System: Stretch Lite rPi
Location: Wilmslow, Cheshire, UK
Contact:

Re: Google map message on website

Post by mcrossley » Wed 22 Aug 2018 9:42 am

I think Street View and Full Page View controls are both enabled by default.

Here is the code on my page for disabling them...

Code: Select all

	<script>
		function initMap() {
			var position = new google.maps.LatLng(53.3250, -2.2428);
			var myOptions = {
					zoom: 8,
					center: position,
					streetViewControl: false,
					fullscreenControl: false,
					mapTypeId: google.maps.MapTypeId.ROADMAP
				};
			var map = new google.maps.Map(document.getElementById("map_canvas"), myOptions);
			var marker = new google.maps.Marker({
									position: position,
									map: map,
									title:"This is the place."
								});

			var infowindow = new google.maps.InfoWindow({content: 'WilmslowAstro Weather'});

			google.maps.event.addListener(marker, 'click', function() {
									infowindow.open(map,marker);
								});
		}
	</script>

User avatar
steve
Cumulus Author
Posts: 26714
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Google map message on website

Post by steve » Wed 22 Aug 2018 9:48 am

The trouble with the Cumulus user map is that it's way out of date - it uses an obsolete version of the Google API. So it really needs reworking anyway. Maybe I'll have a go using leaflet.js, had a quick look and it looks pretty good. As I understand it, it's very easy to switch between mapping providers.
Steve

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 10:06 am

My code looks nothing like yours Mark. This is what I have. Apologies for the mess. I know very little about HTML. Can't see anything there about options to enable or disable.

<td colspan="1">
<div id="map_canvas_custom_20943" style="width:250px; height:300px" ></div>
<script type="text/javascript">
(function(d, t) {var g = d.createElement(t),s = d.getElementsByTagName(t)[0];
g.src = "http://geo-maps.net/en/maps/20943.js?po ... ed+Kingdom";
s.parentNode.insertBefore(g, s);}(document, "script"));</script>
<a class="geomap_link_20943" style="font:8px Arial;text-decoration:none;color:#5C5C5C;text-align: right; display: block; width: 250px;" href="http://geo-maps.net/en">geo-maps.net</a>
<!-- Do not change code! -->
</td>

Looking at that url I remember now I switched to another source for using Google Maps. Can't remember why. http://geo-maps.net/en
Cheers,
Ray, Cheshire.

Image

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 12:31 pm

I used Google to search for embedding Google Map in my website. Somewhat amazingly the first link took me to https://www.embedgooglemap.net.

I went through the process of entering my address and choosing a zoom factor. I don't want my actual address to appear in the link. Here is the code supplied...

<div class="mapouter"><div class="gmap_canvas"><iframe width="250" height="300" id="gmap_canvas" src="https://maps.google.com/maps?q=8%20Woki ... tput=embed" frameborder="0" scrolling="no" marginheight="0" marginwidth="0"></iframe><a href="https://www.pureblack.de"></a></div><style>.mapouter{text-align:right;height:300px;width:250px;}.gmap_canvas {overflow:hidden;background:none!important;height:300px;width:250px;}</style></div>

q appears to hold the address so I should be able to modify that. But where are the options to turn off streetview etc.? Given this is Google's own site you'd think there'd be some mention of whether an API is required and the limitations of not having one.
Cheers,
Ray, Cheshire.

Image

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 12:50 pm

I put that code into IndexT.html and it looks good. Fingers crossed it stays like this.
Cheers,
Ray, Cheshire.

Image

User avatar
steve
Cumulus Author
Posts: 26714
Joined: Mon 02 Jun 2008 6:49 pm
Weather Station: None
Operating System: None
Location: Vienne, France
Contact:

Re: Google map message on website

Post by steve » Wed 22 Aug 2018 1:59 pm

I'm pretty sure that isn't a Google site, it's another free generator site like the other one you were using. There seem to be a large number of these sites, and I'm wondering what's in it for them. There's a link to a German site called 'pureblack' in there, who are web site developers, so presumably that's it. I'd be tempted to remove that.
Steve

RayProudfoot
Posts: 2620
Joined: Wed 06 May 2009 6:29 pm
Weather Station: Davis VP2 with Daytime FARS
Operating System: Windows XP SP3
Location: Cheadle Hulme, Cheshire, England
Contact:

Re: Google map message on website

Post by RayProudfoot » Wed 22 Aug 2018 2:09 pm

Good spot Steve. I think you're right. Why don't Google offer the service free to those who just want a simple map? Strange.

I did as you suggested and removed that url. Hopefully things will still work. I'll know in the next 10 mins.
Cheers,
Ray, Cheshire.

Image

Post Reply