HTML and CSS Reference
In-Depth Information
When you configure Visual Studio to use HTML5 (Visual Studio 2012 uses HTML5 by default), all the
HTML pages and Web Forms you create use the HTML5 style of DOCTYPE declaration. The markup in Listing
1-2 shows the default web form markup created in an ASP.NET web site.
Listing 1-2. Default Markup for a Web Form
<%@ Page Language=”C#” %>
<!DOCTYPE html>
<script runat=”server”>
<html xmlns=””>
<head runat=”server”>
<form id=”form1” runat=”server”>
You can also see HTML5-specific markup tags in Visual Studio IntelliSense (Figure 1-3).
Figure 1-3. HTML5-specific tags in Visual Studio IntelliSense
Although HTML5 and web browsers forgive most markup errors, as a good developer you should
ensure that your HTML5 page markup follows the recommended usage rules. To assist with this task, you
can use the W3C Markup Validation Service: an online utility that validates your HTML and XHTML
documents. Figure 1-4 shows this utility with Hello.htm as the input.
Search WWH ::

Custom Search