【问题标题】:CSS Transform not working in IE 8CSS 转换在 IE 8 中不起作用
【发布时间】:2012-09-23 23:34:52
【问题描述】:

我正在尝试使用 CSS Transform 属性旋转或变换 div。这是我的转换 CSS 代码:

-webkit-transform: rotate(270deg);
-moz-transform: rotate(270deg);
-ms-transform: rotate(270deg);
-o-transform: rotate(270deg);
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=0);
transform: rotate(270deg);

上面的代码在除 IE 8 之外的所有版本中都很好用。我需要找到一种方法来支持 IE 8。

如何为 IE8 创建回退?

注意:我正在使用 jQuery (1.8.2)、HTML 5 Doctype 和 modernizr,如果这对您提供的答案有影响的话。我更喜欢纯 CSS 解决方案,但愿意使用 javascript/jQuery 解决方案。

Here is a fiddle with the HTML and CSS.

【问题讨论】:

    标签: css internet-explorer-8 css-transforms


    【解决方案1】:

    如果您看到“过滤器:”旋转到 3,它将在 IE 8 中旋转 270 度(向下到 v5.5,IIRC)。

    http://msdn.microsoft.com/en-us/library/ms532918(v=vs.85).aspx

    【讨论】:

    • 谢谢,如果我使用它会弄乱 IE9,去算一下。我将在 IE8 及以下和 IE9 及以上使用 IE 条件样式表。
    • 我认为这可能会发生,但我不确定。条件 cmets 肯定会解决它。
    猜你喜欢
    • 2013-09-28
    • 2014-10-07
    • 2013-09-09
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多