Created
May 26, 2018 04:42
-
-
Save wpflippercode/0b119ae1b6714b3e9657356adac70410 to your computer and use it in GitHub Desktop.
Access Map Object Using Javascript
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action("wp_head","fc_reset_zoom"); | |
function fc_reset_zoom() { | |
echo ' | |
<script>jQuery(document).ready(function($){ alert("ok"); | |
$("body").on("click",".test",function(){ var map_obj = $("#map5").data("wpgmp_maps"); map_obj.map.setZoom(8); } | |
); | |
});</script>'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment