I
I
Irina2015-07-15 15:45:14
JavaScript
Irina, 2015-07-15 15:45:14

Problem with Google maps, how to get rid of the gray background?

Good afternoon.
There is a problem with the cards.
When creating a map dynamically, a gray background remains, marked with red.
5a1248cd56a04f62ad35a9e5942aad4a.png

// ...
    var $map = $('<div id="map-canvas" style="width: 100%;  height: 100%;"></div>');
    $mw.find('.for-map').html($map.show())
            setTimeout(function () {
                initialize($data);
            }, 200)
     // ...

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
MhMadHamster, 2015-07-15
@MhMadHamster

trygoogle.maps.event.trigger(map, 'resize');

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question