1) It causes VS 2010 to use HTML5 semantic markup elements like <header>, <footer>, <section> and <nav> within the default layout.cshtml file that is generated. This is instead of just using <div> elements for header/footer/navigation elements – which is
the default behavior if the HTML5 semantic checkbox isn’t selected (and the same behavior that we have shipped earlier).
2) It causes VS 2010 to reference the modernizr.js JavaScript library by default within the layout.cshtml – which among other things will allow you to use CSS to style HTML5 semantic markup elements even with older browsers like IE6 (ensuring your site still
works for older browsers).
However even though I didnt click on enable HTML 5 semantic support.
1. I can select HTML 5 in Doctype on the razor views.
2. I can see intellisense for <header> <footer>, etc.
3. modernizr-1.7.js is there in Visual Studio
Is this a bug? So whats the real difference?
Am I missing something here?
Another question: Can I enable HTML 5 semantic support if I didnt enable it when creating the project?
levalencia
Member
677 Points
340 Posts
Enable HTML 5 Semantic Support.
Oct 13, 2011 08:29 PM|LINK
I created a simple mvc project in vs11 with asp.net mvc 3.
I forgot to check enable Enable Html 5 support.
According to this blog post from Scott
Selecting this checkbox option does two things:
1) It causes VS 2010 to use HTML5 semantic markup elements like <header>, <footer>, <section> and <nav> within the default layout.cshtml file that is generated. This is instead of just using <div> elements for header/footer/navigation elements – which is the default behavior if the HTML5 semantic checkbox isn’t selected (and the same behavior that we have shipped earlier).
2) It causes VS 2010 to reference the modernizr.js JavaScript library by default within the layout.cshtml – which among other things will allow you to use CSS to style HTML5 semantic markup elements even with older browsers like IE6 (ensuring your site still works for older browsers).
However even though I didnt click on enable HTML 5 semantic support.
1. I can select HTML 5 in Doctype on the razor views.
2. I can see intellisense for <header> <footer>, etc.
3. modernizr-1.7.js is there in Visual Studio
Is this a bug? So whats the real difference?
Am I missing something here?
Another question: Can I enable HTML 5 semantic support if I didnt enable it when creating the project?
Thanks