I am creating a popup without source URL using window.open (). I don’t give him the URL, because soon I will want to publish the form. However, at the same time, I would like to display a short message "Now loading ..." so that the user does not look at the blank page for 2-3 seconds, after which the form message should pass.
I tried adding Javascript that just writes to the popup document. This worked great in Firefox and IE 8, but failed with an access denied message in IE 6 and 7. Does anyone know about this? I would like to be able to: a) hard-code some HTML in window.open (), b) learn how to update the pop-up DOM in this situation, or c) hear something you might think about.
Below is the code that I use to create the window:
var wref = window.open("", winName, "toolbar=1,resizable=1,menubar=1,location=1,status=1,scrollbars=1,width=800,height=600");
if (wref != null) {
try {wref.opener = self;} catch (exc) {}
$j(wref.document.body).html('Now loading …');
wref.focus();
source
share