CSS在modalBackground和HeaderFreez中出错 [英] CSS Having Error in modalBackground and HeaderFreez

查看:85
本文介绍了CSS在modalBackground和HeaderFreez中出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在构建解决方案时会显示以下错误,任何人都可以告诉这里发生了什么..

Following Errors are shown while building Solution, Can anybody tell whats wroung here..

.modalBackground
{
      background-color:ButtonShadow;
      filter:alpha(opacity=70);
      opacity:0.7;
}





Error   1   Validation (CSS 2.1): 'filter' is not a known CSS property name.    D:\WebSite1\css\Styles.css    287 4   D:\e-prescription\







.HeaderFreez
{
   /*position:relative ;*/
   position:relative;
   /*top:expression(this.offsetParent.scrollTop);*/
  /* top: expression(this.parentNode.parentNode.parentNode.scrollTop-1);*/
  top: expression(this.parentNode.parentNode.scrollTop-1);
   /*z-index: 10;*/
   z-index:15;
}





Error   3   Validation (CSS 2.1): 'expression(this.parentNode.parentNode.scrollTop-1)' is not a valid value for the 'top' property. D:\WebSite1\css\Styles.css    349 8   D:\e-prescription\

推荐答案

实际上非常简单,无论是过滤器还是表达式在CSS下都是无效的,因此当您尝试构建解决方案时,它在CSS 2.1标准下无法通过验证.

具体来说, filter 是IE特定的,而不是CSS标准的一部分.

Firefox使用属性opacity:x来提高透明度,而IE使用filter:alpha(opacity = x).

提示:透明度的CSS3语法是opacity:x.


expression 值是另一个IE特定的附加内容,它不是有效的CSS.
It actually pretty simple neither filter or expression is valid under CSS as such when you try to build you solution it fails validation under the CSS 2.1 standard.

Specifically filter is IE specific not a part of the CSS standard.

Firefox uses the property opacity:x for transparency, while IE uses filter:alpha(opacity=x).

Tip: The CSS3 syntax for transparency is opacity:x.


The expression value is another IE specific addition that is not valid CSS.


这篇关于CSS在modalBackground和HeaderFreez中出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆