1.

Solve : WC3 validation problem?

Answer»

I'm using a XHTML table format for my sitemap and the file has just one error left to correct:
end tag for "table" which is not finished

Description:
Code: [Select]Most likely, you nested tags and closed them in the wrong order. For example <p><em>...</p> is not acceptable, as <em> must be closed before <p>. Acceptable nesting is: <p><em>...</em></p>

ANOTHER possibility is that you used an element which requires a child element that you did not include. HENCE the parent element is "not finished", not complete. For instance, in HTML the <head> element must contain a <title> child element, lists require appropriate list items (<ul> and <ol> require <li>; <dl> requires <dt> and <dd>), and so on.
 
Code: [Select]<tr valign="top">
<td class="lbullet">&nbsp;&nbsp;&nbsp;&nbsp;</td>
<td class="lpart" colspan="99"><div class="lhead">newsletter11/
</div>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
</table>
</td>
</tr>
If anyone know how to change this in order to validate I would appreciate it.
Any reason for having an empty table? I'm not sure, but that could be causing it.

To be honest, I wouldn't be too worried about validation ANYMORE, especially with XHTML. Most sites are now using HTML5, where validation doesn't really come into it.It seems as though the tags for the table are in the wrong order, shouldn't it be something more like this?

Code: [Select]<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr valign="top">
<td class="lbullet">&nbsp;&nbsp;&nbsp;&nbsp;</td>
<td class="lpart" colspan="99"><div class="lhead">newsletter11/</div></td>
</table>

In the original code, you create a table row, add individual cells, add the table in one of the cells, then close the cell and row.  The new code opens the table, inside this adds a row and inside the row adds the two cells.Thanks for your attention to my html  problem I used your code suggestion unfortunately it added another 40 errors to the validation output. If you don't mind taking another  look at the code at

http://www.jkershaw.info/sitemap.html

you may see the structure of the table. The error "end tag for "table" which is not finished" occurs near lines 145, 338, and 506 in the rows where the newsletter year starts. With only three errors on the page there must be a very small change required. the same error ocurrs at these 3 locations but  the page LOOKS OK to me.
 much appreciated Quote from: kpac on April 18, 2013, 01:12:05 PM

Any reason for having an empty table? I'm not sure, but that could be causing it.
This is definitely it. I took the empty tables out of the code and it validated fine.
I can't see the changes you made. Is it possible to show me here? Really appreciate it. Quote from: springbud on April 21, 2013, 08:47:38 PM
I can't see the changes you made. Is it possible to show me here? Really appreciate it.

just remove these (there are a few of them):


That validates now. Many thanks

http://www.jkershaw.info/sitemap.html


Discussion

No Comment Found