Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CSS border-radius and -moz-border-radius

Tags:

css

I've inherited a web project that is supposed to work in IE8 (as well as the other browsers but I am not worried about them by comparison). When I run the website in Firefox and check the Error Console it mentions:

"Warning: Unknown property '-moz-border-radius'. Declaration dropped"

Wherever -moz-border-radius appears in the style sheet border-radius also appears. For example, these were right next to each other in the style sheet:

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

Is there any reason to keep the -moz-border-radius styling? Is it better to just remove them?

like image 331
asimes Avatar asked Dec 27 '22 11:12

asimes


2 Answers

-moz-border-radius hasn't been necessary in firefox for a long time, so I'd remove it. See:

https://developer.mozilla.org/en-US/docs/CSS/border-radius

-moz-border-radius removed from firefox 13

like image 135
wless1 Avatar answered Jan 13 '23 11:01

wless1


border-radius:20px; will work in all new browsers

-moz-border-radius: was for older versions of FireFox , and -webkit-border-radius: was for older versions of Chrome. Both browsers update them selves so users SHOULD be ok with border-radius: for everything .

I don't see wrong though with adding extra properities in CSS that may not be used by new browsers to ensure that all old browsers also function properly.

like image 20
Scott Selby Avatar answered Jan 13 '23 12:01

Scott Selby