Forum Moderators: open

Message Too Old, No Replies

popup in netscape 4

document.write not working well inside pop-up window

         

dimi78

1:48 pm on Feb 3, 2002 (gmt 0)



Ok i made popup's the way i always do but they asked me to check my site in netscape4 as well (somthing i never did before) and guess what. yep i had to rewrite a lot of the pages, luckly it where small changes but this one i can't figure out. my windows pop- up but all the document.writes don't appear in the windows until you drag the window a bit. any help is apreciated. the code works fine in opera, netscape6 and ie6

tedster

6:44 pm on Feb 3, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to Webmaster World, dimi78

I've never seen this behavior so far, and I check on Netscape 4 all the time. So let's debug what you've got.

The first thing I'd suggest is run your code throught the W3C's HTML validator [validator.w3.org]. If your code is valid and you still have a problem, then show us a code snippet (please replace any specific URLs with something generic) and we might be able to find a fix.

dimi78

9:41 pm on Feb 3, 2002 (gmt 0)



in lotto.htm

<FORM name=ff>
<INPUT type=button value="Opnieuw"name="Opn" onClick="history.go(0);">
<INPUT type=button value="Sluiten" onClick="window.close();">
</FORM>

in a menu.htm

function changetolotto()
{var lotto;
window.location.reload
lotto=window.open("lotto.htm","lotto","width=180,height=340,top=100,
left=100,resizable=no,scrollbars=no,menubar=no,toolbar=no,status=no,location=no");

}
</script>
</head>

<body>
<form>
<table>
<tr>
<td><input type = "button" value = "Mapping" onclick = "changeurl()"></td>
<td><input type = "button" value = "winkel" onclick ="changeToReservatie()"></td>
<td><input type = "button" value = "fotoalbum" onclick = "changetofotoalbum()"></td>
<td><input type = "button" value = "Quiz" onclick = "changetoquiz()"></td>
<td><input type = "button" value = "Lotto" onclick = "changetolotto()"></td>
</tr>
</table>
</form>
</body>
</html>

ofcourse trhes are snippets but the html is checked and it found no folds

tedster

10:35 pm on Feb 3, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Is the FORM tag the snippet that is inserted into lotto.htm with a document.write and then fails to render?

(I edited your above post to avoid horizontal scrolling)

dimi78

8:00 am on Feb 4, 2002 (gmt 0)



yes these are the document.writes that cme in front of it
there's nothing wrong with these. Like i said works fine even in nn4 but you just have to drag the window a bit before it shows the contend. when you refresh the same thing happens, maybe it's a dutch version problem.

document.write("<TABLE align=center bgcolor=tan border=1 ><tr><TH bgcolor=crimson colspan=6><Font size=3>
De lotto getallen</FONT></TH>");
for(i=0;i<42;i++)
{
if(i%6==0)
{
document.write("</TR><TR>");
}
if(checkGetal(i+1,alleGetallen))
{
document.write("<TH bgcolor=lightsteelblue><FONT SIZE=2>"+getallen[i]+"</font></TH>");
}
else
{
document.write("<TH><FONT size=2>"
+getallen[i]+"</FONT></TH>");
}
}
document.write("</TR></TABLE>");
document.write("<BR><H4 align=center>
Het reservegetal is:"+alleGetallen[6]+"</H4><BR>");

tedster

9:53 am on Feb 4, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



It strikes me that form tags sometimes show a sort of disappearing/reappearing behavior on NN4 - and that might be the crux of what you are seeing, rather than an issue with document.write.

Have you tested a pop-up where the form tags are hard coded into the HTML, rather than using document.write, to see if the rendering problem persists?

dimi78

5:23 pm on Feb 4, 2002 (gmt 0)



problem solved thx.