Hi,
I created a page with a form that opens a new window and enters the information from the form in a format that looks better for printing.
It works fine, but when it’s done creating, the browser still keeps “loading”, i.e. the little icon in the upper right corner is still animated as if it were expecting more to come.
Is there a way to send something like an “end of file” command?
I closed all HTML tags properly, and I read that I should put a backslash before the slash in closing tags, but that didn’t work, either.
Here is most of my code (edited because I don’t think the mistake lies in the middle of it where all I do is to add more table data):
[CODE]
function openinvoice() {
invoicewin = window.open(“”,”mywin”,”width=800,height=500,left=0,top=0,location=yes,hotkeys=yes,menubar=yes,resizable=yes,scrollbars=yes,status=yes,toolbar=yes”);
invoicewin.document.write(‘<html><head><title>Invoice</title>n’);
invoicewin.document.write(‘</head> n <body> n’);
invoicewin.document.write(‘<table border=”0″ cellpadding=”0″ cellspacing=”0″ width=”600″> n <tbody><tr> n’);
invoicewin.document.write(‘ <td width=”293″>INVOICE</td> n’);
invoicewin.document.write(‘ </tr><tr> n’);
[…]
invoicewin.document.write(‘<p><strong><font color=”#000099″>THANK YOU FOR YOUR BUSINESS!</font></strong></p> n’);
invoicewin.document.write(‘</body></html>’);
};
// –>
</script>
Is there something wrong with my script, or am I a missing something else?
Thanks!