Having fun with IE - part 2: CSS inheritance

By crisp on Wednesday 29 November 2006 14:09
Category: Browsers, Views: 3.595

Part 2 of this serie; today: CSS inheritance through script.

"Don't touch my inheritance!"

HTML:
1
2
3
4
<p id="foo">whatever</p>
<script type="text/javascript">
  document.getElementById('foo').style.fontSize = 'inherit'; // error
</script>

Volgende: About the cube 12-'06 About the cube
Volgende: Beware of premature optimization 11-'06 Beware of premature optimization

Comments

Comments are closed