internetarchive / openlibrary

One webpage for every book ever published!
https://openlibrary.org
GNU Affero General Public License v3.0
5.59k stars 1.53k forks source link

Fix HTML Validator errors for Edition page #163

Closed bencomp closed 4 years ago

bencomp commented 12 years ago

When I paste an Edition page into the W3C Markup validator, it returns a lot of errors.

The XHTML Transitional validator returns errors like;

Furthermore I have been wondering whether putting title, by-line, edition with <strong> and <br> inside <h1> is good markup. I think it isn't and it may influence the semantic markup as proposed in #84.

randomecho commented 12 years ago

Updating to use HTML5 doctype instead will not care about not closing many non-paired tags (e.g. <meta>, <br>, etc.) and allow for block level <a> usage.

Also, in HTML5 <header> would be better used to group the title, byline and edition data that are currently all sitting inside a <h1>.

bencomp commented 12 years ago

Agreed. The HTML 5 validator did return a lot less errors (which were also due because I had put some RDFa property, typeof attributes etc. in the input). Although it's not an excuse, it will of course be quite a hassle to change everything.

anandology commented 10 years ago

+1 for switching to HTML5.

hornc commented 7 years ago

w3c validator url to validate an Edition: https://validator.w3.org/nu/?doc=https%3A%2F%2Fopenlibrary.org%2Fbooks%2FOL8870170M%2FThe_War_of_the_Worlds_%28Barnes_Noble_Classics_Series%29_%28B_N_Classics%29

Ol now uses the HTML5 doctype <!DOCTYPE html> so that is progress. There are still many validation errors though.

I'm hoping the many "Element div not allowed as child of element span in this context." will be removed with the planned reworking of works and edition pages.

sbshah97 commented 6 years ago

@mekarpeles @hornc is this still an Issue? Is it possible to add a Hacktoberfest label to it or will it be too complicated?

hornc commented 6 years ago

This is still an issue. Probably a larger issue around standardising html across all pages and moving to HTML5. Bumping for discussion and looking for volunteers.

mekarpeles commented 6 years ago

@jdlrobson do you have thoughts on this re: priority? @koderjoker expressed interest in being point on this or finding someone to lead this. Would love your thoughts if there are other front-end tasks you think should be taking priority

jdlrobson commented 6 years ago

Yes. Let's switch to html5 doctype and fix these errors. Invalid HTML can be a huge nuisance (ui regressions, failing js, unreadable content.. even security problems).

They should also be straightforward to fix so if we know about problems lets resolve them with high priority.

brad2014 commented 5 years ago

@koderjoker, let me know if you are still working on this, or are planning to work on this.

koderjoker commented 5 years ago

@brad2014 since I'm not in the middle of working on it and will pick it up most likely after 2-3 weeks, feel free to un-assign me in case a newcomer wants to work on it.

brad2014 commented 5 years ago

I'll leave it as is, no rush! When you pick it up, set the "State: Work In Progress" label.

xayhewalo commented 5 years ago

@koderjoker Any updates to share?

koderjoker commented 5 years ago

@guyjeangilles I paused this issue in favour of working on the navbar at iaux at that time. If no one takes on this issue by the time I'm back (~3 weeks) I'll start working on it and breaking it up to make it more accessible to newcomers.

mekarpeles commented 4 years ago

@koderjoker this issue is currently marked as Work In Progress, how would you like us to label this issue?

koderjoker commented 4 years ago

Paused work on it for the meantime, please remove the Work in Progress label

harsh3125 commented 3 years ago

Yes. Let's switch to html5 doctype and fix these errors. Invalid HTML can be a huge nuisance (ui regressions, failing js, unreadable content.. even security problems).

They should also be straightforward to fix so if we know about problems lets resolve them with high priority.