Advanced Search

Results 1 to 5 of 5

Thread: HTML validation fails

  1. #1
    Join Date
    Jul 2013
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default HTML validation fails

    1) Script Title: All levels menu generator

    2) Script URL (on DD): http://dynamicdrive.com/dynamicindex.../generator.htm

    3) Describe problem: This line fails the W3C validator:

    <validator output>
    Bad value ddsubmenu1 for attribute rel on element a: The string ddsubmenu1 is not a registered keyword or absolute URL.

    <li><a href="/dev/index.shtml" rel="ddsubmenu1">Products</a></li>

    Syntax of link type valid for <a> and <area>:
    A whitespace-separated list of link types, with no duplicate keywords in the list. Each link type must be listed as allowed on <a> and <area> in the HTML specification, or must be listed as allowed on <a> and <area> on the Microformats wiki, or must be an absolute URL. You can register link types on the Microformats wiki yourself.
    </validator output>

    Perhaps one way would be to change the offending link to an absolute URL, but I don't know how to do that. I'm using an SSI for this section, so I can reuse it on every page.

    Btw, the lines that don't have submenus validate fine.

    Any help appreciated!

    Thanks,
    cardioid

  2. #2
    Join Date
    Sep 2007
    Location
    The Netherlands
    Posts
    1,297
    Thanks
    28
    Thanked 135 Times in 130 Posts
    Blog Entries
    28

    Default

    What exactly do you want to be validated? The results of the wizard or the wizard itself (for which http://validator.w3.org gives 54 errors!)?

  3. #3
    Join Date
    Apr 2008
    Location
    So.Cal
    Posts
    3,623
    Thanks
    63
    Thanked 516 Times in 502 Posts
    Blog Entries
    5

    Default

    Arbitrary (e.g., "ddsubmenu") values aren't technically valid on the rel attribute. There are two possible solutions:

    1) If you're validating against HTML5, you can rewrite the markup (and the script) to use a data- attribute instead - i.e., data-ddsubmenu.

    2) Ignore it - while technically invalid, this won't cause any problems at all in any modern browser.
    We Only Torture the Folks We Don't Like (You're Probably Gonna Be Okay)
    It's a Party in the CIA

  4. #4
    Join Date
    Jul 2013
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by traq View Post

    2) Ignore it - while technically invalid, this won't cause any problems at all in any modern browser.
    Sounds good to me. Thanks for the reassurance.

    cardioid

  5. #5
    Join Date
    Jul 2013
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by molendijk View Post
    What exactly do you want to be validated? The results of the wizard or the wizard itself (for which http://validator.w3.org gives 54 errors!)?
    I meant the downloaded code, but, as Traq pointed out, it doesn't appear to be necessary to validate that. Some things don't work in my layout and I'm trying to find the problem. As there were many references to that submenu thing, I thought that this may be the culprit.

    Thanks,
    cardioid

Similar Threads

  1. Resolved HTML validation question
    By james438 in forum HTML
    Replies: 2
    Last Post: 02-25-2012, 06:26 AM
  2. Required field(s) validation script fails in IE8
    By PDXMan in forum Bug reports
    Replies: 0
    Last Post: 06-30-2010, 06:13 AM
  3. Flex Level Drop Down Menu fails to pass XHTML validation
    By hanji in forum Dynamic Drive scripts help
    Replies: 2
    Last Post: 02-12-2010, 09:12 PM
  4. validation fails and page submits on error :(
    By wmguk in forum JavaScript
    Replies: 1
    Last Post: 05-03-2009, 06:17 AM
  5. php form... redisplay if validation fails
    By aegraphic in forum PHP
    Replies: 3
    Last Post: 10-03-2008, 08:28 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •