JQueries是否可以在IE8中工作? [英] Does JQueries Live Work in IE8?
问题描述
我正在使用 jQuery fancy box - 在这个弹出框中我有一个表格选择字段并在更改这些选定字段时,span元素中的值应该改变。我已经得到了这个工作(实际上用了stackoverflow用户的帮助),但该解决方案在IE8中无法正常工作......惊喜......惊喜。
我对选择字段但值不会更改。我想知道是否有人可以通过查看下面的JS代码给我任何想法,为什么这可能是这种情况。现场活动功能现在在IE8中工作吗?!
JS代码:
<$ c $($''select.htt,select.hst')。live('change',function(){
var channels = parseInt($('#fancy_div select.hst')。val(), 10)* parseInt($('#fancy_div select.htt')。val(),10);
$('#fancy_div span.yellow2')。html(channels +'Channels');
});
我在这里粘贴了HTML: http://www.copypastecode.com/13356/ - 它有很多HTML!
谢谢所有的帮助或指导为什么这不适用于IE浏览器。 IE似乎没有注册选择字段的变化。
可能的事件值:click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,keydown,keypress,keyup 不支持:blur,focus,mouseenter,mouseleave,change,submit
I am making use of the JQuery fancy box - in this pop up box I have a form with a few select fields and upon changing these slect fields a value in a span element should change. I have got this to work (actually with stackoverflow users help) but the solution doesn't work in IE8...suprise...suprise.
I make changes to the select field but the value does not change. I was wondering if anyone could give me any ideas why this might be the case by just having a look at the following JS code. Does the live function now work in IE8?!!
JS Code:
$('select.htt, select.hst').live('change', function() {
var channels = parseInt($('#fancy_div select.hst').val(), 10) * parseInt($('#fancy_div select.htt').val(), 10);
$('#fancy_div span.yellow2').html(channels + 'Channels');
});
I have pasted the HTML here: http://www.copypastecode.com/13356/ - its a lot of HTML!
Thanks all for any help or guidance why this isn't working on IE. IE doesn't seem to register the changes of the select fields.
jQuery live does work in IE8, but the live handlers don't support the change event.
Possible event values: click, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, keydown, keypress, keyup
Currently not supported: blur, focus, mouseenter, mouseleave, change, submit
这篇关于JQueries是否可以在IE8中工作?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!