XHTML compliancy and ASP.NET
Some times you'll need for various reasons that your web page is XHTML compliant. However the HTML generated via ASP.NET doesn't validate too well against XHTML 1.0. When one uses <form runat="server"/>, the generated HTML will add a name attribute to the form tag. This is invalid XHTML. The hidden box named __VIEWSTATE needs to be enclosed in a <div> tag. And client-side script blocks should be using type="text/javascript" rather than language="javascript".
People have complaint this so often, some even come up with
work arounds and some with their own
XHTML Web Controls for ASP.NET
Thought the html generated via ASP.NET 2.0(whidbey) is expected to be XHTML compliant.
you may download a pdf about
Validating XHTML within .NET
alternatively u can also use
SgmlReader 1.4 to convert html produced to xhtml
dotnetraj at 07:12 pm on
Tuesday, March 22, 2005