请教一下:怎么在struts中相同文本框中,填写一个文本框后,其他相同属性的文本框自动填值,要一个方法搞定,我在表单中用<html:text property="sortdetailname" size="20" onblur="autoEdit(this,this.value);"/>
再用方法:
function autoEdit(element,value){
document.getElementById('allSortInforForm').elements[element].value=value;
}
allSortInforForm是form的id属性。
如何传this对象?
再用方法:
function autoEdit(element,value){
document.getElementById('allSortInforForm').elements[element].value=value;
}
allSortInforForm是form的id属性。
如何传this对象?
看起来是 把“当前元素”的“值”设置为“当前元素的值”,这不是一句废话么?