小编Shi*_*hed的帖子

仅使用CSS定位Firefox

使用条件注释很容易使用特定于浏览器的CSS规则来定位Internet Explorer:

<!--[if IE 6]>
...include IE6-specific stylesheet here...
<![endif]-->
Run Code Online (Sandbox Code Playgroud)

有时,Gecko引擎(Firefox)行为不端.使用CSS规则而不是单个其他浏览器仅针对Firefox的最佳方法是什么?也就是说,Internet Explorer不仅应该忽略Firefox规则,还应该忽略WebKit和Opera.

注意:我正在寻找一个"干净"的解决方案.在我看来,使用JavaScript浏览器嗅探器向我的HTML添加"firefox"类并不符合要求.我宁愿看到一些取决于浏览器功能的东西,就像条件评论只对IE有"特殊"...

css firefox css-hack

595
推荐指数
8
解决办法
55万
查看次数

宽度属性中的CSS\9

这是什么意思?我猜它是一个浏览器黑客,但我无法找到它究竟是什么.

width: 500px\9;
Run Code Online (Sandbox Code Playgroud)

有什么意义\9

css width css-hack

206
推荐指数
2
解决办法
8万
查看次数

IE8 css选择器

要仅在IE浏览器中定位元素,我将使用

IE6:

* html #nav li ul {
    left: -39px !important;
    border: 1px solid red;
}
Run Code Online (Sandbox Code Playgroud)

IE7:

*+html #nav li ul  {
    left: -39px! important;
}
Run Code Online (Sandbox Code Playgroud)

有谁知道如何定位IE8?

css internet-explorer css-hack

45
推荐指数
7
解决办法
15万
查看次数

如何使CSS仅对Opera可见

有没有办法让一些CSS规则只对Opera(9.5 +)可见?

css opera css-hack

31
推荐指数
5
解决办法
6万
查看次数

如何单独为IE9定义特定的CSS规则?

朋友们,请帮我定义IE9的具体css规则?比如这样

/* IE 6 fix */
* html .twit-post .delete_note a { background-position-y: 2px; }
* html .twit-post .delete_note a:hover { background-position-y: -14px; }
Run Code Online (Sandbox Code Playgroud)

css css-hack internet-explorer-9

26
推荐指数
4
解决办法
6万
查看次数

仅通过CSS定位IE9

只是想知道这些IE黑客入侵我的技巧

"\9" - for IE8 and below.
"*" - for IE7 and below.
"_" - for IE6.
Run Code Online (Sandbox Code Playgroud)

即如

body { 
    border:2px solid blue;
    border:2px solid yellow \9;
    *border:2px solid green;
    _border:2px solid orange;
}
Run Code Online (Sandbox Code Playgroud)

是否有人对IE9有这样的攻击?即我只是想通过CSS瞄准IE9?

html css stylesheet css-hack internet-explorer-9

22
推荐指数
2
解决办法
7万
查看次数

目标IE9或IE8,但不是两者都使用CSS

我知道不应该这样做,但我现在只想快速修复,这将给我时间找到适当的解决方案.

如何使用CSS单独定位IE8因为我尝试追加\9如下:

margin:100px\9;
Run Code Online (Sandbox Code Playgroud)

但是,它也影响IE9,我不希望这样,因为在IE9上整个网站看起来很好.

css internet-explorer css-hack

10
推荐指数
2
解决办法
3万
查看次数

只需要ie9的黑客攻击

是否有针对IE9的黑客入侵?我只在IE9中遇到问题,其他浏览器工作正常.我正在使用\9,但它也影响了IE8.

我不想使用条件评论.

css css-hack internet-explorer-9

10
推荐指数
3
解决办法
5万
查看次数

对于动态创建的元素,Css3变换动画在IE 11中不起作用

我已经将CSS3变换动画应用于动态创建的元素,它可以在Safari,firefox和chrome中运行,但不能在IE中使用.我已经检查了代码和css.他们没有错.

在IE检查器(开发人员工具)中,动画属性用红色下划线标注.不知道这有什么问题.有人可以帮忙吗?

我的CSS

.loadNew {

  -webkit-animation-name: rotate;
  -webkit-animation-duration: 1s;
  -webkit-animation-iteration-count: infinite;
  -webkit-animation-timing-function: linear;

  -moz-animation-name: rotate;
  -moz-animation-duration: 1s;
  -moz-animation-iteration-count: infinite;
  -moz-animation-timing-function: linear;

  -o-animation-name: rotate;
  -o-animation-duration: 1s;
  -o-animation-iteration-count: infinite;
  -o-animation-timing-function: linear;


  /* below animation properties are underlined in red in IE inspector */
  animation-name: rotate;
  animation-duration: 1s;
  animation-iteration-count: infinite;
  animation-timing-function: linear;

}

@-webkit-keyframes rotate {

  from {
     -webkit-transform: rotate(0deg);
  }

  to {
     -webkit-transform: rotate(360deg);
  }
}

@-moz-keyframes rotate {

  from {
    -moz-transform: rotate(0deg);
  }

  to {
    -moz-transform: rotate(360deg);
  }
}

@-o-keyframes rotate …
Run Code Online (Sandbox Code Playgroud)

html css3 internet-explorer-11

7
推荐指数
2
解决办法
3万
查看次数

CSS3动画播放状态的简写在IE和Safari中不起作用

我正在研究在同一元素上不时有多个动画并切换animation-play-state paused到的项目running.

当我试图添加一个具有动画速记语法的类时,包括animation-play-state:running那时它在IE和Safari中不起作用.

.fadein-left {
    -webkit-animation: fadeInLeft 1s 2s both running;
    animation: fadeInLeft 1s 2s both running;
}
Run Code Online (Sandbox Code Playgroud)

jsfiddle链接

但如果我animation-play-state在单独的行中使用,那么它在所有浏览器中都能正常工作.

.fadein-left {
    -webkit-animation: fadeInLeft 1s 2s both;
    animation: fadeInLeft 1s 2s both;
    -webkit-animation-play-state: running;
    animation-play-state: running;
}
Run Code Online (Sandbox Code Playgroud)

jsfiddle链接

我在他们刚才提到的备注部分检查了msdn上的动画属性 -

但是,动画属性不指定animation-play-state属性的值.

是否可以使用animation-play-state速记动画或我必须在单独的行中使用它?

css safari animation internet-explorer css3

6
推荐指数
1
解决办法
1019
查看次数

多个关键帧动画无法在safari中运行

我正在使用HTML5横幅,它有很多CSS3动画.为了制作可重复使用的关键帧动画,我在单个元素上使用多个动画.除了野生动物园,它的工作完美.

CSS:

.text1 {
    -webkit-animation: fadeOutRight 1s 3s forwards;
    animation: fadeOutRight 1s 3s forwards;
}
.text2 {
    -webkit-animation: fadeInLeft 1s 4s both, fadeOutRight 1s 7s forwards;
    animation: fadeInLeft 1s 4s both, fadeOutRight 1s 7s forwards;
}
.text3 {
    -webkit-animation: fadeInLeft 1s 8s both;
    animation: fadeInLeft 1s 8s both;
}

/* fadeInLeft */
@-webkit-keyframes fadeInLeft {
    0% { -webkit-transform: translateX(-100px); opacity: 0; }
    100% { -webkit-transform: translateX(0px); opacity: 1; }
}
@keyframes fadeInLeft {
    0% { transform: translateX(-100px); opacity: 0; } …
Run Code Online (Sandbox Code Playgroud)

safari html5 animation css3 css-animations

6
推荐指数
1
解决办法
991
查看次数

TweenMax和TweenLite之间的区别?

TweenMax&之间是否有任何速度或垃圾收集差异TweenLite

实际上目前我正在网站上工作,我正在使用超过500补间TweenMax,并且网站在Firefox中完美运行但在chrome和safari tween非常糟糕.

基于GC和速度的TweenMax和TweenLite之间的区别?

garbage-collection google-chrome tweenlite greensock tweenmax

5
推荐指数
1
解决办法
3141
查看次数