Is it time to bring back the table missing summary warning? #210
A post on
As stated in my reply, there are perhaps 2, or more, bugs here!
Case 1: First at present tidy5 no longer emits this warning in ANY case, which may be fine for html5 mode... But is it?
Case 2: Conversely, if the document IS html5, and you DO add a summary attribute, tidy5 does NOT warn that the summary attribute is not supported in HTML5 ;=(( Should it?
Case 3: Further, if the doctype declares the document as an earlier doctype, like say 4.01 strict, or transitional, htm4--, tidy5 still does not emit the warning ;=(( Should it?
The missing summary warning was REMOVED back on Nov 21, 2011, commit/4fdc30c (4fdc30c) by @sideshowbarker, with the comment "summary attribute is not required on table in HTML5". That seems fine if tidy5 was only ever meant to support html5...
But now we want it to support ALL html, so is it time to bring back this warning?
Should it ALWAYS be there as it was in tidy before 2011?
Or should an appropriate warning ONLY be issued for Cases 2 and/or 3 above?
Or other ideas...
I seek comments in this before jumping down a path ;=)).
See the thread https://lists.w3.org/Archives/Public/html-tidy/2015AprJun/0009.html for some discussion on alternatives to this table summary attribute...
@skynet thanks for the comment. I would agree supporting html5, but there are still some questions.
I have constructed 4 test files, all with a table, and put them to the W3C validator, and to tidy 4.9.32 and show the results - (NWORE = No warnings or errors were found)
Test 2 shows me the validator is serious about
Here I suggest a new warning like
And also for case 3, when the document is NOT html5, output the usual summary warning, even though the validator sees nothing wrong. That is restoring tidy's previous behaviour.
Anyway, baring any convincing comments to the contrary, this is how I will proceed.
It's done ;=)) Bumped version to 4.9.33 for this change.
1. in_210-1.html - html5, no summary - remains NWORE
2. in_210-2.html - html5, with summary - NEW WARNING
3. in_210-3.html - html4, no summary - OLD WARNING retored
4. in_210-4.html - html4, with summary - NWORE
Look forward to testing and comments...