P
paolomatador
Hello!
I've a little problem.
I've created a dynamic popup with the document.write method with a form
in it to pass some variables I need.
After the page is created I want to submit the form automatically, but
I dont know how, doesn't works.
Here's the code!
var whandle =
window.open("about:blank","pdf",",directories=no,menubar=no,scrollbars=yes,resizable=no,width="+(larghezzaschermo-100)+",height="+(altezzaschermo-100)+",top=50,left=50");
whandle.document.writeln("<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0
Transitional//EN'>");
whandle.document.writeln("<HTML><HEAD><TITLE>RIEPILOGHI
CONTABILI</TITLE>");
StrMess += sepRecord;
whandle.document.writeln("<BODY topmargin=0 leftmargin=0 rightmargin=0
bottommargin=0>");
whandle.document.writeln("<form name='miostr' action='creaxml.jsp'
method='post' target='pdf'><input type='hidden' name='StrMess'
value='"+StrMess+"'><input type='hidden' name='titolo'
value='"+titolo+"'><input type='hidden' name='param'
value='"+parent.parent.parametri+"'><input type='submit'></form>");
whandle.document.writeln("</BODY>");
whandle.document.writeln("</HTML>");
whandle.document.writeln("<script type='text/javascript'>");
whandle.document.writeln("document.miostr.submit();");
whandle.document.writeln("</script>");
I think the problem is that the page isn't still completed when try to
submit the form, and something happens.
Instead, if I specify the target of the form as _blank, everything goes
well and the form submit.
If I want to submit on the same page, doesnt works.
Anyone knows how?
Thanks in advance.
Paolo.
I've a little problem.
I've created a dynamic popup with the document.write method with a form
in it to pass some variables I need.
After the page is created I want to submit the form automatically, but
I dont know how, doesn't works.
Here's the code!
var whandle =
window.open("about:blank","pdf",",directories=no,menubar=no,scrollbars=yes,resizable=no,width="+(larghezzaschermo-100)+",height="+(altezzaschermo-100)+",top=50,left=50");
whandle.document.writeln("<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0
Transitional//EN'>");
whandle.document.writeln("<HTML><HEAD><TITLE>RIEPILOGHI
CONTABILI</TITLE>");
StrMess += sepRecord;
whandle.document.writeln("<BODY topmargin=0 leftmargin=0 rightmargin=0
bottommargin=0>");
whandle.document.writeln("<form name='miostr' action='creaxml.jsp'
method='post' target='pdf'><input type='hidden' name='StrMess'
value='"+StrMess+"'><input type='hidden' name='titolo'
value='"+titolo+"'><input type='hidden' name='param'
value='"+parent.parent.parametri+"'><input type='submit'></form>");
whandle.document.writeln("</BODY>");
whandle.document.writeln("</HTML>");
whandle.document.writeln("<script type='text/javascript'>");
whandle.document.writeln("document.miostr.submit();");
whandle.document.writeln("</script>");
I think the problem is that the page isn't still completed when try to
submit the form, and something happens.
Instead, if I specify the target of the form as _blank, everything goes
well and the form submit.
If I want to submit on the same page, doesnt works.
Anyone knows how?
Thanks in advance.
Paolo.