WordPress.org

Ready to get started?Download WordPress

Forums

Slideshow
[resolved] HTML5 Validation (6 posts)

  1. hydrurga
    Member
    Posted 1 year ago #

    My HTML5 pages containing slideshows are currently not validating on the W3C Markup Validation Service. The error generated is:

    Element style not allowed as child of element div in this context. (Suppressing further errors from this subtree.)

    referring to the inserted code:

    <style type="text/css">

    3 lines after: `<!-- WordPress Slideshow Version 2.1.23 -->'

    Is there any way to recode this to prevent such invalidation, or does the dynamic nature of the css not allow this (without recourse to Javascript)?

    http://wordpress.org/extend/plugins/slideshow-jquery-image-gallery/

  2. Stefan Boonstra
    Member
    Plugin Author

    Posted 1 year ago #

    That's correct. Slideshows are almost always loaded after the '</head>' tag is closed, which means the stylesheets will have to be output on the page.

    Although outputting stylesheets to the page isn't valid, it is not an issue to any browser unless you're using an HTML1 strict doctype.

    A solution to this invalid approach will probably be released in version 2.3.0, which has not been assigned a release date yet.

  3. hydrurga
    Member
    Posted 1 year ago #

    Thanks for the explanation Stefan. HTML5 validation isn't a priority for me in this case since, as you point out, browsers in the real world all accept stylesheets in the body section. I do know however that some organisations insist on their coders/contractors producing compliant code. I found an interesting article here: http://html5doctor.com/the-scoped-attribute/ . Keep up the good work and thanks for producing such a great plugin.

  4. rcemory
    Member
    Posted 1 year ago #

    Release 2.2.8 appears to have cured this minor issue. Suggest closing this thread as resolved.

  5. hydrurga
    Member
    Posted 1 year ago #

    Thanks for the heads-up rcemory, and thanks to Stefan for having resolved this. Keep up the great work!

  6. Stefan Boonstra
    Member
    Plugin Author

    Posted 1 year ago #

    No problem, I'm glad it's finally done correctly!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic