BlockUI 和 UpdatePanel 的 sIFR 3 问题 (IE)

发布于 2024-08-11 03:42:57 字数 455 浏览 2 评论 0原文

我在使用 sIFR 3、jQuery BlockUI 和 UpdatePanel 时遇到问题,页面刷新且 SIFR 字体消失。

在我用来处理 UI 的阻塞和解锁的 Javascript 文件中,我检测到部分回发并解锁 UI:

prm.add_endRequest(function() { $.unblockUI(); });

如果我在此代码块中重新运行 sIFR.replace(),则会呈现 sIFR 字体,但 # 字符正在替换我的页面标题(在浏览器窗口/选项卡的顶部)。这似乎只发生在 IE 中(如图)。每次我使用 LinkBut​​ton 刷新页面时,都会添加一个额外的 # 字符,因此我的页面标题最终看起来像“#########”。知道为什么会发生这种情况吗?

我是否应该运行特定的 sIFR.update() 函数?如果我执行 sIFR.redraw() 或 sIFR() 我会收到 javascript 运行时错误。

I am experience an issue using sIFR 3, jQuery BlockUI and an UpdatePanel where the page refreshes and the SIFR font disappears.

In the Javascript file I use to handle the blocking and unblocking of the UI, I detect the partial postback and unblock the UI:

prm.add_endRequest(function() {
$.unblockUI(); });

If I re-run sIFR.replace() in this code block the font sIFR font is rendered, but # characters are replacing my page title (in the top of the browser window/tab). This seems to only happen in IE (go figure.) Each time I refresh the page using the LinkButton an extra # character is added, so my page title ends up looking like "#########". Any idea why this is happening?

Is there a specific sIFR.update() function I should be running instead? If I execute sIFR.redraw() or sIFR() I get javascript run time errors.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

说谎友 2024-08-18 03:42:57

这是由 IE 中的一个错误引起的:

这是 IE 中的一个非常特殊的错误,对于页面中的每个 Flash 影片,URI 的片段标识符部分 (#foo) 在文档标题中重复。据 Macromedia 报道,可以通过更新浏览器使用的 VBScript 引擎来修复此错误。然而,对于那些仍然拥有错误引擎的用户,sIFR 包含一个解决方法。
http://wiki.novemberborn.net/sifr/Fragment+Identifier+Bug

sIFR 3 有一个解决方法,但除非页面加载了片段标识符 (window.location.hash != ""),否则它不会启动。在您的情况下,我假设加载的页面没有标识符,然后添加一个,然后重新运行替换,重新调用该错误。

您可以通过打开sifr.js(压缩版本)并替换this.fix=c.ua.ieWin&&window.location.hash!="" 通过 this.fix=c.ua.ieWin

This is caused by a bug in IE:

This is a very peculiar bug in IE where for each Flash movie in the page the fragment identifier part of the URI (#foo) is repeated in the document title. It has been reported by Macromedia that this bug can be fixed by updating the VBScript engine the browser uses. However, for those users who still have the wrong engine sIFR contains a workaround.
http://wiki.novemberborn.net/sifr/Fragment+Identifier+Bug

sIFR 3 has a workaround but it doesn't kick in unless the page is loaded with a fragment identifier (window.location.hash != ""). In your case, I assume the page is loaded without the identifier, then you add one, and then you re-run replacements, reinvoking the bug.

You can patch r436 by opening (the compressed version of) sifr.js and replacing this.fix=c.ua.ieWin&&window.location.hash!="" by this.fix=c.ua.ieWin.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文