Author: Ian Skinner
So I have been playing with some of the few CSS3 tricks that are
available in Mozilla browsers, such as the Corner Rounding:
-moz-border-radius: 25px; property.
This works a real treat, so then I took a gander at the W3C CSS
validation tool but it does not like this property, as far as it is
concerned it does not exist. It would be happy with the generic
'border-radius' property, but no browser supports this, as far as I know.
I thought the browser specific '-moz' was considered good, standard
practice these days? Is this just a case of the validation tool not
properly recognizing this?
And is there any simple trick that would allow me to keep the
functioning, Mozilla specific CSS3 features and still get a passing
validation from the W3C tool?
Author: Peter Boughton
> I thought the browser specific '-moz' was considered good, standard
> practice these days?
Using browser specific anything is never good practise.
Especially browser specific things that are named after a browser.
Might be the only way to achieve something sometimes though, so...
> And is there any simple trick that would allow me to keep the
> functioning, Mozilla specific CSS3 features and still get a passing
> validation from the W3C tool?
Your main stylesheets should have the standards version only.
Create [stylesheet-name].[browser]fix.css for any browser-specific fixes.
(e.g. "main.css" has "main.iefix.css", "main.mozfix.css", etc.)
Then, as browsers fix things, you can just reduce/remove the fix files
whilst leaving your main stylesheets untouched.