Playing with selects and javascript
- by Tom
My code is:
<select name='main'>
<option>Animals</option>
<option>Food</option>
<option>Cars</option>
</select>
<select name='other'>
<option>Rats</option>
<option>Cats</option>
<option>Oranges</option>
<option>Audi</option>
</select>
How do I filter my second select, so it would only show items which I want eg. if I Choose Animals, my select would be:
<select name='other'>
<option>Rats</option>
<option>Cats</option>
</select>
and if I choose Food, my select would be:
<select name='other'>
<option>Oranges</option>
</select>
Well, I hope you get the idea. Thanks.