Topic awaiting preservation: loop problem |
|
---|---|
Author | Thread |
Paranoid (IV) Inmate From: NZ |
posted 06-05-2003 23:37
Hi, guys. How are you today? quote:
code: <html>
|
Nervous Wreck (II) Inmate From: Indianapolis, In USA |
posted 06-06-2003 11:18
Just a guess, but when you rewrite the document on the first time through the loop, the browser may be forgetting that it has something else to do. You might try writing the output to a textarea input. |
Maniac (V) Mad Scientist From: 127 Halcyon Road, Marenia, Atlantis |
posted 06-06-2003 14:33
right now your second page has nothing on it but "i(number) Blastoff" because thet's all you printed to it... you gotta imagine it's a completely different text file.... |
Paranoid (IV) Inmate From: A graveyard of dreams |
posted 06-06-2003 23:22
The problem with this line, for(i=document.theForm.num.value; i=document.theForm.end.value; i--), is that it is causes the loop to only run once. |
Maniac (V) Mad Scientist From: 100101010011 <-- right about here |
posted 06-07-2003 01:56
Actually that's only going to run once too since he's decrementing i, in this case your basically doing (i =3; i >= 3; i--) |
Paranoid (IV) Inmate From: A graveyard of dreams |
posted 06-07-2003 12:32
Not really.. As long as the document.theForm.num.value is greater than document.theForm.end.value it will work. The code would then resemble something like for(i=5; i>=3; i--), which should work. |
Paranoid (IV) Inmate From: NZ |
posted 06-10-2003 23:54
Hi, guys. How are you today? code: <html>
|
Maniac (V) Inmate From: Brisbane, Australia |
posted 06-11-2003 00:16
Try this: code: <html><head>
|