我保证,我已经阅读了数百个 Joyent 帖子和 stackoverflow 问题,我会先说我确定我没有放错逗号并安装了 flash 并且已经让其他人在 IE 中尝试了该页面。
问题是在 IE 6/7 中没有任何渲染,但 IE8、FF 和 Safari 都很好。这是代码:
//sIFR-config.js
var zapfino = { src: '/fonts/zapfino.swf' };
sIFR.fitExactly = true;
sIFR.useStyleCheck = true;
sIFR.useDomLoaded = true;
sIFR.activate(zapfino);
sIFR.replace(zapfino, {
selector: 'h1, h2, h3, h4'
,css: '.sIFR-root { color: #1A2F35; }'
,forceSingleLine: true
,tuneWidth: 5
,wmode: 'transparent'
,filters: {
DropShadow: {
knockout: false
,distance: 3
,color: '#330000'
,strength: 1
,alpha: .45
}
}
,ratios: [7, 3.59, 9, 3.56, 10, 3.49, 12, 3.5, 13, 3.46, 20, 3.47, 23, 3.43, 26, 3.44, 34, 3.42, 40, 3.41, 42, 3.4, 45, 3.41, 47, 3.4, 49, 3.41, 69, 3.4, 71, 3.39, 72, 3.4, 76, 3.39, 77, 3.4, 3.39]
});
/* sIFR.css */
@media screen {
.sIFR-active h1, .sIFR-active h2, .sIFR-active h3, .sIFR-active h4 {
visibility: hidden;
font-family: Verdana;
line-height: 1em;
color: #ff0000;
}
.sIFR-dummy {
width: 0px;
height: 0px;
margin-left: 42px !important;
z-index: 0;
}
}
<!-- HTML Snippet -->
<div id="header">
<H1>H1 Example</H1>
<h3>H3 Example</h3>
<h2>H2 Example</h2>
<h4>H4 Example</h4>
</div>
请注意,您看到的几乎每个选项我都尝试过,有无缓存清除等。此外,主 css 绝对将 h1-4 定位在 div#header 中,我也尝试将其注释掉。
编辑:请注意 .sIFR-active 类应用于<html>
,所以我知道脚本正在触发,但除此之外页面上没有任何内容被更改。
我也尝试过来自不同来源的不同字体,但在 IE 中仍然没有运气。
TIA,
周杰伦