Click to See Complete Forum and Search --> : HTML validation troubles


Kriegster
05-03-2009, 06:33 PM
I've got 3 errors left for my HTML validation; and here they are:

Line 14, Column 56: Attribute "height" exists, but can not be used for this element.

…" align="center" width="935" height="208" border="0" cellpadding="0" cellspac



You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).

This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.

And that line is:

<table id="Table_01" align="center" width="935" height="208" border="0" cellpadding="0" cellspacing="0">

I'm not sure how to fix this or why it's coming up, but since my other 2 errors are the exact same (invalid attributes), I'll just see if I can get this one fixed and follow accordingly. I wish I could link to the site, but I've got it blocked off via .htaccess while I build it :\. So, if anyone could tell me why this isn't working I'd be greatly appreciative. P.S.: the doctype is correct.

tracknut
05-03-2009, 07:08 PM
Looking at the allowed attributes for a table at http://www.w3schools.com/tags/tag_table.asp it doesn't look like "height" is one of them.

Dave

Charles
05-03-2009, 07:19 PM
Here the definitive list of attributes: http://www.w3.org/TR/html401/index/attributes.html . W3Schools isn't always spot on.

Kriegster
05-03-2009, 09:27 PM
The problem is, is that I have some errors which the HTML validator says I can't use (I.E. the attribute background with a <td> tag). Yet, if I remove those, my site looks ****ed up (I.E. those attributes actually are doing something). So, what do I do? I want to be W3 valid on everything (I've taken care of the CSS validation), but this HTML is being a *****. I donno what to do.

tracknut
05-03-2009, 10:10 PM
It's hard to make recommendations without seeing the site.

Kriegster
05-03-2009, 10:19 PM
It's hard to make recommendations without seeing the site.

Okay, it's http://kid.thenewivo.com . Login credentials for the server side auth is guest:guest. Thanks guys.

tracknut
05-03-2009, 10:35 PM
I'm looking at the site, and it just looks to me like you've designed the site to some IE proprietary standards. Have you tried putting your TABLE and TD backgrounds in as CSS styles instead?

Dave

Kriegster
05-03-2009, 11:04 PM
I'm looking at the site, and it just looks to me like you've designed the site to some IE proprietary standards. Have you tried putting your TABLE and TD backgrounds in as CSS styles instead?

Dave

I didn't really want to go that route, but I ended up just doing it. And now I'm 100% XHTML 1.0 Transitional :D. Thanks tracknut.