Reply
Tue 31 Mar, 2009 12:05 am
i really do need some help, i just need to replace a textbox everytime the combolist is changed, but it's just so hard. i have tried it in radiobutton and it worked. here's my code:
function changeClient() {
var theForm = document.forms[0];
var customerType = document.getElementsByName("customerType");
var customerTypeValue;
for(i=0; i<customerType.length; i++) {
if(customerType.checked == true) {
customerTypeValue = customerType.value;
}
}
theForm.customerType.value = customerTypeValue;
theForm.search.value = false;
resetSearchFields();
theForm.action = "<%=request.getContextPath()%>/aw/clientmgrprepareaction.do";
theForm.submit();
}
<tr>
<td class="FormText_1" width="26%">Client Type
<html:select property="customerType" tyleClass="FormText_1">
<option value=""><%=Constants.EMPTY_DESCRIPTION%></option>
<logic:present name="clientMgrForm" property="customerTypeOptions">
<bean:define id="customerTypeOptions" name="clientMgrForm" property="customerTypeOptions" />
<html:options collection="customerTypeOptions" property="shortVal" labelProperty="description" />
</logic:present>
</html:select>
</td>
</tr>
<tr>
it will be a big help for me,,. thanks
That looks like .NET to me that will then generate the HTML. I don't do .NET, but I can probably solve your problem on the client-side level.
If I do so would that help you? And would you be able to convert my markup and JavaScript into the .NET code you need? Or should I just wait for a .NET developer to show up?
Looks like jsp plus javascript to me. I don't see where you're actually doing anything on change, is something missing?
@FreeDuck,
FreeDuck wrote:Looks like jsp plus javascript to me.
Ah yes, I see a bean. Still, not something I'm any good at.
@Robert Gentel,
Me neither. There was a time, maybe 5 or 6 years ago, when I did this kind of work, but I'm totally rusty now.