0
Use default:
<input type="radio" name="restype" value="resdef" onfocus="document.getElementById('resupload').disabled = true; document.getElementById('resadres').disabled = true;" checked="checked" /><br />
Adres:
<input type="radio" name="restype" value="resadres" onfocus="document.getElementById('resupload').disabled = true; document.getElementById('resadres').disabled = false;" />
<input type="text" name="resadres" id="resadres" disabled="disabled" /><br /><br />
Upload:
<input type="radio" name="restype" value="resupload" onfocus="document.getElementById('resadres').disabled = true; document.getElementById('resupload').disabled = false;" />
<input type="file" name="resupload" id="resupload" disabled="disabled" />
此代碼在Firefox和IE瀏覽器,但無法在Chrome。哪裏有問題?的JavaScript啓用谷歌瀏覽器/禁用文本框/文件中的字段的onfocus事件問題
非常感謝你 – 2011-06-10 09:25:53