views:

998

answers:

4

I'm using Chris Pederick's Firefox addon "Web Developer 1.1.6". I get this warning when hitting a certain web page on my site:

Unknown property 'MozOpacity'. Declaration dropped.

What does this mean and how can I fix this on my site?

+1  A: 

Are you using mozopacity in your CSS stylesheet? This might be spelled wrong and is thus triggering an error.

You might be looking for -moz-opacity which has been dropped as of Firefox 3.0.

Ross
I don't have "MozOpacity" in any of my stylesheets.
LordHits
That seems rather confusing then - which Firefox version are you using?As said, FF3 does not support -moz-opacity, but you are using the latest webdev toolbar. This could possibly be a bug, or that when WebDev inspects the DOM it finds FF has added it in. Try checking the DOM in Firebug.
Ross
I'm using Firefox 3.0.3. What am i supposed to be looking for in the DOM tab in Firebug?
LordHits
A: 

there is some proprietary css declaration : - filter (from microsoft); - -moz-corner-radius, -moz-opacity and other -moz prefixed from mozilla - -khtml prefixed from safari

these are NOT standard and it works ONLY in that browser. If you don't expect -moz properties to work on safari and filter on firefox, you can ignore that warnings :)

Ionut Staicu
+2  A: 

It's customary for browsers to prefix experimental or proprietary features with -moz (for Gecko-based browsers) or -webkit (for webkit) so they can be used but don't interfere with standard CSS rendering. In the case of -moz-opacity, it seems that they have finally removed the proprietary tag since the standard opacity tag is supported.

I don't think any equivalent convention is followed by the IE team, but then again IE is so behind the pack it probably never came up ;)

Adam Lassek
-webkit is used for webkit and starting with IE8, -ms will be used for IE.
Nouveau
I'm pretty sure that until recently it was -khtml. You are correct that it is -webkit now.
Adam Lassek
+1  A: 

It might not be an issue with your site. Some browser plugins - for instance, Firebug or Web Developer - often add extra styles dynamically to the page for debugging purposes; I've noticed the unofficial -moz-* styles pop up in my own Firefox debugging.

However, this isn't necessarily a problem with your page; it could be a problem that your user agent is first creating itself, and then assuming later that there's a problem with your page.

First, I suggest trying to disable your Firefox plugins and seeing if you still get aforementioned error. Then, make sure your plugins are up-to-date - especially any development/debugging type ones that might be manipulating the DOM after pageload.

infovore