Wednesday, October 21st, 2009
- <meta name="description" content="test me" />
- alert(description.content); // "test me"
Furthermore, you can use
document.getElementById('description') will give you that DOM node although it has no ID!
Stoyan has a test page up to see what browser behaves that way and there’s an interesting comparison table in the blog post. Also be sure to check the comments for more baffling findings.
Posted by Chris Heilmann at 10:35 am