select不支持readonly,只能用其他办法去模拟readonly了,效果就是点击select选择元素,然后自动变回默认的。
<select id="test" οnfοcus="this.defaultIndex=this.selectedIndex;" οnchange="this.selectedIndex=this.defaultIndex;">
<option value="1">test1</option>
<option value="2">test2</option>
<option value="3">test3</option>
<option value="4"<span style="font-family: Arial;"> selected="selected"</span><span style="font-family: Arial;">>test4</option></span>
<option value="5">test5</option>
</select>