Uploaded image for project: 'MyFaces Core'
  1. MyFaces Core
  2. MYFACES-1774

HtmlLinkRenderer should output & instead of & as the url param separator within href attribute according to HTML Spec

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.1.5, 1.2.0
    • 1.1.7, 1.2.7
    • General, JSR-127, JSR-252
    • None

    Description

      Currently a <h:outputLink> with nested <f:param> components is rendered as
      <a href="somepage?foo=1&bar=2">...</a>

      According to http://www.w3.org/TR/html401/ the character entity "&" should be used instead of "&":
      "Authors should use "&" (ASCII decimal 38) instead of "&" to avoid confusion with the beginning of a character reference (entity reference open delimiter). Authors should also use "&" in attribute values since character references are allowed within CDATA attribute values."

      Though current browsers seem to have no problem with "&" characters within href attributes, this issue gets serious when using XHTML. Not using the character entity "&" instead of "&" leads to invalid (not well-formed) XML data!
      Therefore I think we should fix this.

      BTW, the RI renders the wrong "&" as well.

      Attachments

        Issue Links

          Activity

            People

              manolito Manfred Geiler
              manolito Manfred Geiler
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: