如何使用CSS来显示边框图像?
此代码仅在Google Chrome和Mozilla Firefox中显示边框图像,但不显示在IE 9或10中。需要对CSS和WordPress中使用的代码进行哪些更改?有没有我可以用来实现这个插件?如何使用CSS来显示边框图像?
.Offset1 {
width:525px;
height:auto;
float:left;
margin-left:8px;
border-style:double;
border-width:30px 30px 30px 30px;
-moz-border-image:url("<?php echo $vtheme_options['logo']; ?>") 30 30 30 30 stretch stretch;
-webkit-border-image:url("<?php echo $vtheme_options['logo']; ?>") 30 30 30 30 stretch stretch;
-o-border-image: url("<?php echo $vtheme_options['logo']; ?>")30 30 30 30 stretch stretch;
border-image:url("<?php echo $vtheme_options['logo']; ?>") 30 30 30 30 stretch stretch;
behavior:url(PIE.htc);
position: relative;
}
@media (max-width: 767px) {
.Offset1{ width:222px;
margin-left:3px;
}
}
据我所知,物业border-image
不被Internet Explorer支持。看到这个1小例子的代码。尝试使用不同的浏览器,除Internet Explorer之外的所有工作。
:请发送示例。 – sumitdadhich 2013-02-25 13:41:23
这是因为Internet Explorer doesn't support border-image, at all和PIE's support is very specific and limited,更不用说在IE10中完全不支持。
换句话说,你必须有非常具体的代码,每个PIE的文档,让它在IE9和更低版本中工作,并且你根本不会在IE 10中工作。
我强烈建议只对Internet Explorer进行回退并完成它。
:你好请回复一下IE9和IE10中的一些代码示例支持。 – sumitdadhich 2013-02-26 05:39:44
@sumitdadhich - 你不会*获得*支持IE10。这是我的观点,你将不得不根据我为你链接的文档来玩你的代码,以使IE9正常工作。 – Shauna 2013-02-26 13:51:05
@Shauna听起来像'IE生气'开发人员的答案。 – 2013-02-26 13:55:18
你在哪里有背景图片?或者你的意思是'边界图像'? IE 9及以下版本不支持'border-image'。对于IE 10它可能会与'-ms-border-image'一起工作 – 2013-02-25 12:30:27
offset1是类 – sumitdadhich 2013-02-25 12:32:43
这已经是.offset1 – sumitdadhich 2013-02-25 12:36:16