I think you should try this, send the script or function. example. $("#form_dialog").dialog({ /*some options */}) .load("url",{}, function(){ $("head").html("<scr" + "ipt>\n" + "function step1() {\n" + " setTimeout('step2()', 10);\n" + "}\n" + "function step2() {\n" + " window.print();\n" + " window.close();\n" + "}\n" + "</scr" + "ipt>\n") });
- [jQuery] .load() and executing JavaScript from loaded co... Benjamin Wohlwend
- [jQuery] Re: .load() and executing JavaScript from ... Wolf
- [jQuery] Re: .load() and executing JavaScript f... Benjamin Wohlwend
- [jQuery] Re: .load() and executing JavaScri... Carlos Becar
- [jQuery] Re: .load() and executing Java... Benjamin Wohlwend
- [jQuery] Re: .load() and executing... Charlie
- [jQuery] Re: .load() and execu... Benjamin Wohlwend
- [jQuery] Re: .load() and e... Julijan Andjelic