Did anyone have problems with Google Maps API? I have an HTML with OpenLayers and Geoserver. Since yesterday, the Google Maps Hybrid map is not working, even if some images are loaded in Firebug. Sometimes I receive a message stating Google Maps API v3.2 is deprecated.

 var map, info;

    function load() {
        map = new OpenLayers.Map({
    div: "map",allOverlays: true, projection: new OpenLayers.Projection("EPSG:900913"),
    displayProjection: new OpenLayers.Projection("EPSG:4326"),
    layers: [
       // new OpenLayers.Layer.Google("Google Satellite",{type: google.maps.MapTypeId.SATELLITE, numZoomLevels:50}),
        new OpenLayers.Layer.Google("Google Hybrid",{type: google.maps.MapTypeId.HYBRID, numZoomLevels:20}),
        cladiri=new OpenLayers.Layer.WMS(
                {layers: 'proprietati:<?php echo "".$identificator."_cladiri";?>',transparent: true, format: 'image/png'},
                {isBaseLayer: true, opacity: 0.9, singleTile: true})
    controls: [
        new OpenLayers.Control.Navigation({
            dragPanOptions: {
                enableKinetic: true
        new OpenLayers.Control.PanZoom(),
        new OpenLayers.Control.Attribution()
    center: new OpenLayers.LonLat(26.1473586305531, 44.4431676053183).transform(new OpenLayers.Projection("EPSG:4326"), new OpenLayers.Projection("EPSG:900913")),
    zoom: 15

enter image description here

1 Answer 1


No, not having any issues with Google Maps, including Hybrid. Maybe you could try using the current version of the API from Google's SVN?

<script type="text/javascript" src="http://maps.google.com/maps/api/js"></script>

  • I changed the js. Still not working. I will put my code in question. The strange thing is that in firebug some images from google hybrid are loading. Feb 17, 2016 at 18:52
  • Ok - it does appear likely that the API changed in a way that broke OpenLayers, and was forecast according this ( github.com/openlayers/ol2/issues/1450 ), which mentions 3.20 will be deprecated and 3.21 causes an issue in OpenLayers. OpenLayers looks like it has been changed to handle this, but in the master branch, not the CDN (see the very last comment). Looks like this is your workaround - get the latest OpenLayers.js from the master branch, save it on your web server, update your page(s) to point to your locally hosted version and this issue hopefully will be resolved.
    – Eric
    Feb 17, 2016 at 19:01
  • I use openlayers 2.13.1. Got to go to 3 :) Feb 17, 2016 at 19:28
  • Simple solution - changed Google Maps to Bing maps. Feb 18, 2016 at 20:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.