Setting the Value of a text box based on the value of a Select Box
Here is what I need to do.
1: I have a select box of CND Provinces, the value of each is the ISO two character code (eg: MB, AB, BC, etc...)
2: Each province needs a different numerical tax value.
3: When I change the select box, I want the correct value for that province to appear in a text box.
In the example below, I know I need to write a function called "setTax" but I do not know where to begin.
If AB is chosen, the value has be be 5
If ON is chosen, the value has to be 13
If BC is chosen, the value has be to 12
Here is a sample of my select box
<select name="province" onchange="setTax(document.Form, this.value);">
<option value="">Select Province from List...</option>
<option value="BC">British Columbia</option>
Here is my text box
<input name="showtax" type="text" id="showtax" value="<show-value-of-tax-here" />
Any help would be appricated!