JS 動的に読込み

MEMO


var scriptInc1 = document.createElement("script");
scriptInc1.setAttribute("type", "text/javascript");
scriptInc1.setAttribute("language", "JavaScript");
scriptInc1.setAttribute("src", "http://xxxxxx/xxxxxx.js");
document.getElementsByTagName("head")[0].appendChild(scriptInc1);

//bodyにappendChildしてもいいと思うが?...


if(typeof 「動的に入れたfunction」 == 'function' ){
読込まれた...; // ここの判定はタイマーなどで、、、
}

// 多分...