[thelist] .Net generated HTML not validating - help?

aardvark evolt at roselli.org
Wed Oct 5 16:28:23 CDT 2005

On 6 Oct 2005 at 6:52, Ken Schaefer wrote:
> > value of attribute "ID" invalid: "_" cannot start a name.
> Is this issue important? Not sure - personally I don't think so. As far as I
> know, no browser cares that your IDs begin with a _ rather than an
> alphanumeric character.

from experience...

the leading underscore can (and will) hose JS and CSS calls... i 
don't have specific examples, but i ran into it months ago... i also 
relied on name/id being the same on form fields in the old days, but 
.NET uses dashes on one, and colons on the other... sorry, no 
examples handy...

as a result, we have built our own controls to output cleaner code, 
or in most cases, i write the HTML myself and remove .NET from the 
rendering of the HTML for all but the most complex elements...

More information about the thelist mailing list