简体   繁体   English

CSS - 新的Firefox版本不再显示Border-Image

[英]CSS - New Firefox-release doesn't show Border-Image anymore

After the Firefox update the Border Image doesn't show up anymore at all? Firefox更新后,边框图像根本不会显示? You might have defined somthing like this: 你可能已经定义了这样的东西:

border-width:30px;
-moz-border-image: url('border.png') 64 64 64 64 stretch stretch;
   -webkit-border-image: url('border.png') 64 64 64 64 stretch stretch;
   -o-border-image: url('border.png') 64 64 64 64 stretch stretch;

I had to look around for a bit to realize it's a Firefox Problem. 我不得不环顾四周才意识到这是一个Firefox问题。 First I thought AdBlock might have just blocked it for some reason. 首先我认为AdBlock可能因为某些原因而刚刚阻止了它。 It's actually a change Mozilla did to their CSS Interpretation. 这实际上是Mozilla对CSS解释所做的改变。 You now MUST add this property underneath it for it to work: 你现在必须在它下面添加这个属性才能工作:

border-style:solid;

Hope I could help. 希望我能提供帮助。

As per the specifications, Firefox requires border-image-width to be set. 根据规范,Firefox需要设置border-image-width

Just include the above property. 只需包含上述房产。

Here, border-style will correct the issue, but to be more logical and related, its better to use border-image-width instead of border-style or border-width sometimes. 在这里, border-style将纠正问题,但为了更合乎逻辑和相关,有时使用border-image-width而不是border-styleborder-width更好。

Consider adding: 考虑添加:

border: 15px solid transparent;

Where 15px is just an example. 15px只是一个例子。

添加fill

-webkit-border-image: url(<%= asset_path('wxskvip_head_frame.png') %>) 6 fill stretch;

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM