[英]CSS Round corners In IE
我正在使用此 .htc邏輯對內容標簽進行四舍五入,但無法正常工作。 我的標簽結構如下所示。
<li id="profiletab1" class="selected">
<a href="#">Overview</a>
</li>
<li id="profiletab2" class="">
<a href="#">Overview</a>
</li>
...
CSS代碼為此
color: #4f4f4f;
height: 35px;
display: inline-block;
padding: 0px 18px 0px 19px;
font-size: 14px;
line-height: 35px;
-webkit-border-radius: 5px 5px 0px 0px;
-moz-border-radius: 5px 5px 0px 0px;
border-radius: 5px 5px 0px 0px;
behavior: url(border-radius.htc);
background: #e7e7e7;
background: -webkit-gradient(linear, 0 0, 0 bottom, from(#e7e7e7), to(#cccccc));
background: -webkit-linear-gradient(#e7e7e7, #cccccc);
background: -moz-linear-gradient(#e7e7e7, #cccccc);
background: -ms-linear-gradient(#e7e7e7, #cccccc);
background: -o-linear-gradient(#e7e7e7, #cccccc);
background: linear-gradient(#e7e7e7, #cccccc);
-pie-background: linear-gradient(#e7e7e7, #cccccc);
border-right: 1px solid #b1b1b1;
您需要使用:
behavoir:url(PIE.htc)
在課程結束時
IE 9之前不支持CSS 3
使用
border-radius在CSS中
加
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
和
如果您想在IE 7/8中使用它們,
您將需要一些有關JavaScript庫的幫助。
可以在任何IE瀏覽器中使用嗎? 還要仔細檢查.htc文件的路徑
我正在使用PIE.htc方法,而我的CSS就是這樣。
#maincol #content {
float:left;
background-color:#FFF;
width:100%;
height:399px;
-moz-border-radius:0 0 10px 10px;
-webkit-border-radius:0 0 10px 10px;
border-radius:0 0 10px 10px;
behavior: url(../css/PIE.htc);
}
另外,我已經測試並驗證了它可以在IE的所有版本中使用。 我所要做的就是將pie.htc文件放在我的CSS文件夾中,然后將行為添加到我想弄清楚的元素中。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.