A
A
Artemiy1172015-12-23 19:03:35
css
Artemiy117, 2015-12-23 19:03:35

How to properly center google map through div?

Dear webmasters. Need help.
I am implementing a google map on the site. I do through the layer. There will be several points on the map. I take one of them as the center. That is, I set the coordinates as the center of the map. As a result, my card "moves out" somewhere up to the left. And the center of the map is obtained in the upper left corner of the div.
When the map was displayed through an iframe, it also moved out, but it was possible to achieve it through css using text-align and a couple more normal display parameters. But then it was necessary to redo it for the output of several points. And this trick no longer works through div.
Here is an example: www.intrust-tour.ru/country/tailand/hotels/h238647.html on the map tab.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
@
@ksider, 2015-12-23
@Artemiy117

In general, this problem was solved for me by loading the map while clicking on the taboo.
and so the problem with display:none is known stackoverflow.com/questions/16167440/jquery-1-9-1-...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question