开发者

Javascript Form Onchange hack with Google Chrome and IE7

<form onchange="return valid('form changed')">
 <select>
  <option>uno</option>
  <option>dos</option>
 </select>
 <input type="radio" name="videoDevice" value="cuatro" checked="checked" />
</form>开发者_运维百科;

onchange event is not working with google chrome and ie7 ... how to hack it ... onchange is not required on select tag and we can't use jquery ...


there is no onchange event

you need onsubmit to validate prior to posting to the server
or
to hook up some events on the dom elements onclick, onchange depending on the element
that inform the user directly


You can use jquery on the input as well.

$("input").change(function(){ //Do stuff here });
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜