简体   繁体   English

将jquery从1.2.7升级到1.9.1时出现的问题

[英]Issues while upgrading jquery from 1.2.7 to 1.9.1

I'm in the process of upgrading an old codebase containing jquery v1.2.7 to the v1.2.9. 我正在将包含jquery v1.2.7的旧代码库升级到v1.2.9。 The corresponding UI upgrade is from v.1.6b to v1.9.2 (1.10 doesn't work with IE6). 相应的UI升级是从v.1.6b升级到v1.9.2(1.10不适用于IE6)。 There are a bunch of ui plugins that are atleast 6 yrs old, and most of their authors no longer actively support them. 有很多至少6岁的ui插件,并且他们的大多数作者都不再积极支持它们。

I took a layered approach of performing this. 我采用了分层的方法来执行此操作。 I first upgraded all the core files (jquery, jqueryUI), then upgraded inhouse js code (attr, $.browser) and such. 我首先升级了所有核心文件(jquery,jqueryUI),然后升级了内部js代码(attr,$。browser)等。 Then I monkey-patched some of the plugins that had attr and browser. 然后,我用猴子修补了一些具有attr和浏览器的插件。 I've managed to work through all the bugs and errors so far. 到目前为止,我已经设法解决了所有错误和错误。 I now have a "clean" build, with a lot of the ajax functionality working as well. 我现在有了一个“干净”的构建,并且许多ajax功能也可以正常工作。

BUT, I'm facing a pretty sticky issue with the facebox.js (yup THAT relic) plugin. 但是,我面临着facebox.js(是那个遗物)插件的一个非常棘手的问题。 I don't see any errors (js, network, or others) in the debuggers (IE8,FB,Chrome), but the facebox dialog displays incorrectly. 我在调试器(IE8,FB,Chrome)中看不到任何错误(js,网络或其他错误),但是面板对话框显示不正确。 It still displays the content inside it, but it is transparent and the background and edges do no show. 它仍然显示其中的内容,但是它是透明的,并且背景和边缘不显示。 I checked all my css as well as validated using w3c validator. 我检查了所有CSS并使用w3c验证程序进行了验证。 Due to an NDA, I can't post the markup here. 由于NDA,我无法在此处发布标记。 I realize that without the markup, even the considerable expertise here might not be able to give a complete solution. 我意识到没有标记,即使是这里相当多的专业知识也可能无法提供完整的解决方案。 Could someone atleast give me some pointers on what I could be overlooking, or things to look for? 至少有人可以给我一些有关我可能忽略的内容或要寻找的东西的指示吗? TIA TIA

eastwood 伊士活

As you said, without markup it's difficult to figure out what's going on there, and my answer might be really stupid - but since you don't get any errors in the debug consoles and the box is transparent - is it possible that the images are missing/incorrectly referenced in the CSS? 如您所说,没有标记就很难弄清楚那里发生了什么,我的回答可能真的很愚蠢-但是由于您在调试控制台中没有任何错误并且盒子是透明的-图像是否可能在CSS中缺少/引用不正确?

Not sure how this old facebook.js plugin works, but I've seen one some time ago that used images for backwards compatibility with IE6 (for alpha transparency/rounded borders) - but not always. 不知道这个旧的facebook.js插件如何工作,但是我前段时间看到过使用图像与IE6向后兼容(用于alpha透明/圆角边框),但并非总是如此。 I think for modern browsers it drew that stuff itself. 我认为对于现代浏览器,它本身就是吸引人的东西。 (pretty much like Facebook did it itself on its site) (很像Facebook在其网站上自行完成的工作)

So perhaps the error is related to JavaScript expecting images/etc. 因此,错误可能与JavaScript期望图像/等有关。 to be handled by CSS, but the CSS uses an only-IE6-hack? 由CSS处理,但是CSS使用仅是IE6-hack?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM