開いている子ウィンドウのドキュメントが読み込まれ、準備ができたときに通知を受け取ろうとしています。これは機能していないようです:
win = window.open(href, 'test', 'width=300, height=400');
win.focus();
$(win.document).ready(function() {
// Ok, the function will reach here but if I try to manipulate the
// DOM it doesn't work unless I use breakpoints
$(this).contents().find("...").doStuff(); // nothing happens
});
私は何をしなければなりませんか?