我正在开发一个应该与IE7,IE8和IE9兼容的Web应用程序。另外,我想在CSS中使用border-radius
和box-shadow
属性。我遇到了CSS3 PIE,我已将其添加到我的项目中,如下所示,
然后我使用TextBox
创建了Button
和ASP.NET
,并在CSS文件中添加了以下样式,
.textbox, .button
{
font-size: 17px;
border: 2px solid rgb(153, 0, 0);
transition: 0.3s ease-in all;
-webkit-border-radius: 10px;
-moz-border-radius: 10px;
border-radius: 10px;
-webkit-box-shadow: inset 0px 2px 2px 2px rgba(250, 250, 250, 2);
-moz-box-shadow: inset 0px 2px 2px 2px rgba(250, 250, 250, .2);
box-shadow: inset 1px 2px 2px 1px rgba(250, 250, 250, .2);
position: relative;
z-index: 0;
height: 30px;
behavior: url(~/PIE/PIE.htc);
}
但即使我使用了CSS3 PIE插件,border-radius
和box-shadow
也无法在IE7和IE8中运行。他们要我添加position: relative;
和z-index: 0;
,所以我添加了它们。此外,我添加了behavior: url(/path/PIE/PIE.htc);
属性,但仍然无效。我在这里做错了吗?我在这里使用VS 2010。