Skip to content Skip to sidebar Skip to footer

Degradation Issues For Html5 Semantic Tags (article, Footer, Header)

How well do the new layout tags in HTML5 degrade? What are the hazards in using them? (I'm not talking about

Solution 1:

As long as you use html5shiv to handle IE, it will work fine.

The browser will treat all unknown tags (including HTML5 tags) as normal inline elements. You should include the following CSS rule:

article, aside, figure, footer, header, hgroup,
menu, nav, section { display: block; }

Solution 2:

For presentation you'll use CSS anyhow, so doesn't really matter if browser understands the tag itself.

Solution 3:

HTML 5 Tags are not supported in IE the tags are still inactive. To activate the semantic HTML5 tags in IE use the following script inside your head section.

<!--[ifIE]>
<scripttype="text/javascript">
(function(){
var html5elmeents = "address|article|aside|audio|canvas|command|datalist|details|dialog|figure|figcaption|footer|header|hgroup|keygen|mark|meter|menu|nav|progress|ruby|section|time|video".split('|');
for(var i = 0; i < html5elmeents.length; i++){
document.createElement(html5elmeents[i]);
}
}
)();
</script>
<![endif]-->

Post a Comment for "Degradation Issues For Html5 Semantic Tags (article, Footer, Header)"