异步加载google地图

function loadScript() {
var script = document.createElement("script");
script.type = "text/javascript";
script.src = "http://maps.google.com/maps/api/js?sensor=false&callback=initialize";
document.body.appendChild(script);
}

window.onload = loadScript;

posted @ 2012-02-29 16:31  kyiku  阅读(882)  评论(0编辑  收藏  举报