jquery - How to center embedded Google Map -


i have fancybox loads remote page via ajax. page uses jquery tabs plugin. on tab not activated default there embedded google map. code calls google maps

<iframe width="740" height="380" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com/maps?z=16&amp;t=m&amp;q=<?= $geo['latitude'] ?>+<?= $geo['longitude'] ?>&amp;hl=ru&amp;output=embed"></iframe> 

the result map shows searched location in top left corner. want center map in coordinates $geo['latitude'] , $geo['longitude'].

i tried add different query parameters ll, sll, no success. tried set iframe preload setting of fancybox false - no result. should do?

consider following example:

<iframe width="740" height="380" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="http://maps.google.com/maps?f=q&amp;source=s_q&amp;hl=en&amp;geocode=&amp;q=museum+near+washington,+united+states&amp;aq=0&amp;sll=40.702863,-74.055748&amp;sspn=0.025669,0.055747&amp;ie=utf8&amp;hq=museum&amp;hnear=washington+d.c.,+district+of+columbia&amp;ll=38.913976,-77.05111&amp;spn=0.052698,0.111494&amp;t=h&amp;z=14&amp;iwloc=a&amp;cid=4718114823360363843&amp;output=embed"></iframe> 

play around ll parameters center map.

also did have @ official google maps api ?


Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -