- From: David Dailey <david.dailey@sru.edu>
- Date: Tue, 03 Apr 2007 11:53:30 -0400
- To: public-html@w3.org
I'm not sure if this is an HTML problem or a CSS problem or an ECMA
script problem, so am not sure if it belongs in this discussion or
not. I suppose it has to do with the orthogonality principle.
Consider the following:
<html>
<body
onload="document.getElementById('R').innerHTML=document.getElementById('Q').style.background">
<div style="background:#afa" id="Q">Bonjour</div>
<div id="R"></div>
</body>
</html>
It doesn't matter if I use innerHTML or a DOM2 nodeValue approach --
alert() shows the same discrepancy.
The string returned by different browsers differs:
IE -- #afa
Firefox -- rgb(170, 255, 170) none repeat scroll 0% 0%
Opera -- #aaffaa
One can program around it, but it is a bit counterintuitive to me
that one gets three different answers.
David Dailey
Received on Tuesday, 3 April 2007 18:51:05 UTC