Question

Locked

Auto file field need additional help

By artty ·
Hello,
I have a form that enters information into a text field when an item is selected form a dropdown field.

My question is
I want to enter the price into different text field based what is selected from the drop down field.
Below is what I have completed. I just cannot figure out the rest. I would appreciate any help. I am still new to this.


<html>
<head>
<script type="text/javascript">
function populate(item){
for(var i=0;i<item.form.elements.length;i++){
if(item==item.form.elements){
item.form.elements.value=
item.options[item.selectedIndex].value;
}
}
}
</script>
</head>
<body>
<form>

<select onchange="populate(this)">
<option value="">Select Product</option>
<option value="(Shirt) (Long Sleve) (Linen Green) (WCB) (1x) (General) (500)">1A1</option>
<option value="(Shirt)(Long Sleve)(Basket Green)(WCB)(1x)(General)(300)">1A2</option>
<option value="(Shirt)(Long Sleve)(White)(WCB)(1x)(General)(200)(Enter Option)">1A3</option>
<option value="(Shirt)(Long Sleve)(Linen Blue)(WCB)(1x)(General)(500)">1B1</option>
<option value="(Shirt)(Long Sleve)(White)(WCB)(1x)(General)(500)">1B2</option>
<option value="1(Shirt)(Short Sleve)(White)(WCB)(1x)(General)(500)">1C1</option>
<option value="(Shirt)(Short Sleve)(White)(WCB)(1x)(General)(1000)">1C1A</option>
<option value="(Shirt)(Short Sleve)(White) (WCB)(1x)(General)(2000)">1C1B</option>
</select>
<br>
<table width="550" height="40" border="1">
<tr>
<td width="534" height="35" align="center" valign="middle"><p>
<input name="Product Ordering" type="text" id="Product Ordering" size="85">
</p>
<p>
<input name="Price" type="text" id="Price">
</p></td>
</tr>
</table>
<br>
<br>

</form>
</body>
</html>

This conversation is currently closed to new comments.

2 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Answers

Share your knowledge
Back to Software Forum
2 total posts (Page 1 of 1)  

Related Discussions

Related Forums