Stoffel
01-19-2003, 01:19 PM
Hiya,
It may be a stupid question, but I am kind of new in JavaScript.
I have a form, and in that form, I want to calculate the price of a movie.
First you have to choose between VHS or DVD and then between the number you want to buy of the movie.
How do I make a script that does that, but it may only be activated when a movie is chosen.
Here is a part of the code:
<form>
<input type="text" name="moviename" value="" size="30" maxlength="100" disabled>
<a href="#" onclick="window.open('pop1.html','','top=100,left=100,width=350,height=400'); return false;">Choose your movie</a>
<select name="type">
<option value="vhs">VHS</option>
<option value="dvd">DVD</option>
</select>
<select name="how_many">
<option value="1">1</option>
<option value="2">2</option <option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
</select>
<input type="text" name="price" value="" size="10">
</form>
The price of the movie can be put in the popup.
I hope you understand what I'm meaning, and that you can help me
See ya
It may be a stupid question, but I am kind of new in JavaScript.
I have a form, and in that form, I want to calculate the price of a movie.
First you have to choose between VHS or DVD and then between the number you want to buy of the movie.
How do I make a script that does that, but it may only be activated when a movie is chosen.
Here is a part of the code:
<form>
<input type="text" name="moviename" value="" size="30" maxlength="100" disabled>
<a href="#" onclick="window.open('pop1.html','','top=100,left=100,width=350,height=400'); return false;">Choose your movie</a>
<select name="type">
<option value="vhs">VHS</option>
<option value="dvd">DVD</option>
</select>
<select name="how_many">
<option value="1">1</option>
<option value="2">2</option <option value="3">3</option>
<option value="4">4</option>
<option value="5">5</option>
</select>
<input type="text" name="price" value="" size="10">
</form>
The price of the movie can be put in the popup.
I hope you understand what I'm meaning, and that you can help me
See ya