jquery focus怎么失效啊??在事件里面
$("#txt").change(function () {
$(this).focus();
});
这代码没问题吧,怎么调用focus就是没效啊···
[解决办法]
firefox和chrome没用,可能事件冲突了,ie可以。。改成下面就行。。
$("#txt").change(function () {
var me = this;
setTimeout(function () { $(me).focus(); }, 1);
});