[英]problems with .change(function() javascript in ie<9
i have problems with this script in ie<9. 我在ie <9中对此脚本有问题。 what problems with my script?
我的脚本有什么问题? thanks
谢谢
ie7,8 error: SCRIPT87: Invalid argument. ie7,8错误:SCRIPT87:无效的参数。 jquery.js, line 3 character 32369
jquery.js,第3行字符32369
in jquery.js: function(a){this.parentNode.insertBefore(a,this.nextSibling)}; 在jquery.js中:function(a){this.parentNode.insertBefore(a,this.nextSibling)};
$(":radio[name=variant]").change(function() {
var vat = $(this).val()
/*$(this).parent().parent().find('td.cost').css("display", "none");
$("#costVariants_"+val).css("display", "block");
*/
$(this).parent().parent().parent().find('label.variant_color').css("border", "none");
$(this).parent().parent().parent().find('span.price').css("display", "none");
$("#color_"+vat).css("border", "1px solid white") ;
/*$("#price_"+vat).css("display", "block") ;*/
$("#price_"+vat).insertAfter($(this).parent().parent().find('.main_image'));
$(this).parent().find('.main_image').html($(this).parent().find('span.price').html());
$(this).parent().parent().parent().parent().parent().parent().parent().find('.main_image').html($(this).parent().parent().find('span.price').html());
});
and i'm sorry, this is my first post here. 很抱歉,这是我在这里的第一篇文章。 thanks a lot
非常感谢
thanks, i read some docs, and now i'm try allways avoid .parent. 谢谢,我阅读了一些文档,现在我尽力避免使用.parent。 But in general my problem was in hiden .
但总的来说,我的问题出在藏身之处。 ie<9 can't select label (the label of input was a color block in my project), when the input is hiden (display: none;)
当输入隐藏时,ie <9无法选择标签(输入的标签是我的项目中的一个色块)(显示:无;)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.