Uploaded image for project: 'MyFaces Tomahawk'
  1. MyFaces Tomahawk
  2. TOMAHAWK-1027

JScookmenu is generating malformed HTML when usign ThemeOffice theme

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.1.6
    • 1.1.7
    • JS Cook Menu
    • None
    • Mozilla Firefox 2.0

    Description

      When usign JS cook menu with ThemeOffice the default implementation generates malformed HTML when the menu have sub-menu itens.

      In the generated HTML is missing some </td>

      I fix this problem changing the line 195 of JSCookMenu.js from
      str += '<td class="' + classStr + 'Text">' + item[1];
      to
      str += '</td><td class="' + classStr + 'Text">' + item[1] +"</td>";

      I did not test it on all possible cenarios. but this change seems to perform well.

      This is specially bad when using facelets that require XHTML. As the XHTML is mandatory to be a wellformed HTML Firefox halts the execution of the script when it tries to print the result
      on line 321 obj.innerHTML = str;
      Apparently Internet Explorer doesn´t check HTML generated by Javascript and the menu works fine even on facelets.

      Attachments

        Activity

          People

            cagatay_civici Cagatay Civici
            lucasam@gmail.com Lucas Machado
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: