开发者

FF6 CSS Javascript MozBorderRadius not working

开发者 https://www.devze.com 2023-04-03 09:44 出处:网络
I\'m trying to set MozBorderRadius via JavaScript in FF6 but it doesn\'t seems to work. If I use WebkitBorderRadius on Safari it works.

I'm trying to set MozBorderRadius via JavaScript in FF6 but it doesn't seems to work. If I use WebkitBorderRadius on Safari it works.

that.element.style.WebkitBorderRadius = '10px'; <- works in Safari

that.element.style.MozBorderRadius = '10px'; <- does not work in FF6

Could someone confirm this开发者_运维技巧?

EDIT :

FF5 same problem.

Something like this is working ok: that.element.style.width = '200px';


The prefix in -moz-border-radius* properties was dropped.
You will have to add that.element.style.borderRadius to support all modern browsers.


Here is what MozillaDev says: In Gecko 2.0 -moz-border-radius is renamed to border-radius. -moz-border-radius is supported as an alias for a transitional period (at least until the next version of Gecko). In order to conform to the CSS3 standard, Gecko 2.0.

I tend to use this service for CSS: http://border-radius.com/. Maybe consider jQuery for the task of styling.

Best of luck!

0

精彩评论

暂无评论...
验证码 换一张
取 消