So i made a script to calculate factorials using 1 to 20. It would display them on the page using document.write.
What I now want to do is make the start and end number user inputs using 2 forms and a button.
I'm not completely sure how to do this. Using just the default stuff I would think it's something like
in the buttons code. This doesn't work. I'm trying to kill 2 birds with 1 stone here. Passing arguments and reading input.Code:onclick="factorial(document.form1.textfield, document1.form1.textfield2);"
What am I doing wrong? I am not even sure if the whole document.form1 thing is even close to being correct.
I'll probably have tons of questions over the next few weeks, so thanks for helpin me out.



Reply With Quote


Bookmarks