views:

31

answers:

1

I understand that with a few simple arrangements, the new HTML5 elements can be used even in older browsers. Does this mean the browsers simply don't really care about what the tags are named? So would there be any critical issues with making up your own elements, like <comments></comments> or <feature></feature> or <chapter></chapter> or whatever, instead of using id's and classes?

I realize it's pretty stupid and unnecessary, but from a hypothetical point of view, would it be likely to cause any actual problems?

A: 

For Internet Explorer to show your new tags, you need to do this in JavaScript:

document.createElement('comments');

The new element will have no styles and defaults to display: inline;.

Other than that, you can use any tags you want.

Be sure to use HTML5's doctype: <!DOCTYPE html>

Coronatus