aync 別のビューをロードし、current を document.write に置き換えるビューを用意しました (はい、ページ全体を置き換えたいです!):
$.ajax({
type: "GET",
url: myUrl,
data: null,
async: true,
success: function (result) {
document.close();
document.open();
document.write(result);
document.close();
},
error: function (req, status, error) {
$("#loading-div").html("error");
}
});
コンテンツは、独自のスクリプトと css スタイルで完全に表示されます。IE または Chrome を使用すると、すべて正常に動作します。Firefox 内でページをロードすると、document.write 経由でロードされたページが正しく機能していないようです - 特にスクリプト (一部は機能し、一部は機能しません)。
スクリプトが評価されないため、innerHTML を使用できません。
Firefox だけで正常に動作しないのはなぜですか (IE でも処理できます!)。