IE7 中的无效参数:jQuery 和前置
当 prepend 方法尝试执行时,下面的代码会呈现无效参数错误。
// close button
closers = overlay.find(conf.close || ".close");
if (!closers.length && !conf.close) {
closers = $('<div class="close"></div>');
overlay.prepend(closers);
}
这是 jquery.overlay.js 的一部分,并且该错误仅发生在 IE7 中。在 IE8、FireFox 和 Chrome 中运行良好。我已使用警报来验证 Closers 和 Overlay 是否都是有效对象。以前有人遇到过同样的错误吗?关于 IE7 中的故障排除有什么想法吗?
任何想法都将不胜感激。
The below code renders an invalid argument error when the the prepend method tries to execute
// close button
closers = overlay.find(conf.close || ".close");
if (!closers.length && !conf.close) {
closers = $('<div class="close"></div>');
overlay.prepend(closers);
}
This is part of the jquery.overlay.js and the error is only happening in IE7. Works fine in IE8, FireFox and Chrome. I've used alerts to verify that closers and overlay are both valid objects. Has anyone encountered this same error before? Any ideas on troubleshooting within IE7?
Any ideas are greatly appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试使用字符串而不是 jQuery 对象:
我不知道它是否有效或为什么它应该有效:-)
但尝试一下并告诉我是否有效......
try a string instead of a jQuery object:
I don't know if it works or why it should work :-)
But try it and tell me if it worked...