You’re viewing an archive of outdated material. Visit The Web Standards Project’s updated site to learn about our current mission.
This page has the following stylesheet:
color:maroon P.two {color: red; }
This text, which has class two, should not be red.
When Opera sees :maroon
, it should parse maroon as
a pseudo-class / pseudo-element. Since the only pseudos Opera knows
are :link
, :visited
, :active
,
:first-line
, and :first-letter
, the entire
selector should be ignored. Why is this a problem? Opera is using
a strange heuristic to determine whether something before a selector
was actually code that should have been within a block, but wasn't.
If opera thinks that that was code that should have been in a block,
it ignores it and parses the rest of the selector. However, this
heuristic, as do most workarounds of this type, has serious bugs (see
the second example). The
entire selector should be ignored because of the standard rules for
parsing: if error selection varies across browsers, the web will become
a big mess, because each browser will be "forgiving" in
different ways.