繁体   English   中英

Firefox中的div圆角不起作用

[英]rounded corners to a div in firefox not working

我想在Firefox中为div添加圆角。 我试过了:

    -moz-border-radius: 20px;

它不起作用。

请问有人有其他解决方案吗?

谢谢

较新版本的Firefox仅支持

border-radius: 20px;

你尝试过吗? 否则,我将需要查看更多的CSS。

将以下所有三个内容放入CSS

-moz-border-radius: 20px; 
-webkit-border-radius: 20px; 
border-radius: 20px; 

一些旧版本使用-moz和-webkit,但是最近的浏览器版本采用CSS3样式方式。

来源: http : //www.the-art-of-web.com/css/border-radius/

正如@vidiya提到的

始终确保涵盖所有方面:

-moz-border-radius: 20px; 
-webkit-border-radius: 20px; 
border-radius: 20px; 

我建议您查看LESSSASS以便您可以使用mixins(CSS中的函数)

 //From LESS
.rounded (@round:"4px") {
    -moz-border-radius: @round; 
    -webkit-border-radius: @round; 
    border-radius: @round; 
}

暂无
暂无

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

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