Ajax Accordion 和 IE8 渲染问题
我有一个在代码中生成的手风琴控件。今天早些时候,它在 IE8 中停止正确渲染。它可以正常工作,但有时布局会被破坏,并且会出现各种奇怪的图形故障。在 Firefox 中并没有失败。
我将 IE 设置重置为出厂默认设置并修复了该问题。它在另一台测试机器上完美运行,但在我们网络上的某些机器上出现图形问题。
有其他人经历过同样的事情或知道修复方法吗?我们所有的计算机都运行 Internet Explorer 8。如果它成为一个大问题,我会尝试强制兼容模式,但我更喜欢更持久的修复(而且这甚至可能无法解决问题!)。
I have an accordion control that is generated in code. Earlier today it stopped rendering correctly in IE8. It would function ok, but sometimes the layout would get corrupted, and all kinds of weird graphical glitches occured. It did not fail in firefox.
I reset my IE settings to factory defaults and it fixed it. It works perfectly on another test machine, but on some of the machines on our network the graphical issues occur.
Has anyone else experienced the same or know a fix? All of our computers run internet explorer 8. If it becomes a big problem I will try forcing compatibility mode but I would prefer a more permenant fix (and also that might not even fix the issue!).
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我过去也遇到过类似的问题,最常见的是某些 CSS 设置的问题。如果您使用 IE 中的开发人员工具,请查看正在应用哪些 CSS 设置并尝试排除这种情况。
正在发生的情况和应该发生的情况的屏幕截图与代码示例一起很有用。
I've had issues like this in the past, most typically an issue with some CSS settings. If you use the developer tools in IE, look to see what CSS settings are being applied and try to rule that out.
A screenshot of what is happening and what should happen would be useful along with the code sample.
仅在手风琴标题上放置以下 css 代码:
.accordionHeader { display: table;宽度:100%;如果
您发现标题在它们之间悬停时仍然跳跃,请使用纯色的边框顶部,而不是使用边距和填充。当然,这只适用于纯色的设计(边框颜色需要与背景颜色匹配)。下面是一个例子:
.accordionHeader { border-top: 10pxsolid #FFFFFF;这
将立即修复 IE8!这花了我一年的时间才弄清楚,哈哈。
On your accordion headers only, place the following css code:
.accordionHeader { display: table; width: 100%; }
If you find that the headers still jump when hovering between them, use a border-top using a solid colour rather than using margin and padding. Of course this only works on designs ontop of solid colours (the border colour would need to match the background colour). Heres an example:
.accordionHeader { border-top: 10px solid #FFFFFF; }
This will fix IE8 right up! This has taken me a year to figure out lol.