Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-45075

Please create the ability to choose between using HtmlUtil.escape() or HtmlUtil.escapeAttribute() via a property

    Details

    • Type: Feature Request
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Please create the ability to choose between using HtmlUtil.escape() or HtmlUtil.escapeAttribute() via a portal property

      This important because URLs in page source escaped with HtmlUtil.escapeAttribute() breaks WebSEAL and presumably other proxies

      The default value of the property should be: HtmlUtil.escapeAttribute()

      Other info:
      It turned out that this escaping method was introduced in LPS-25382 and Sam Kong intentionally changed the usage of the escape() method to escapeAttribute() (see https://github.com/liferay/liferay-portal/commit/110bf722fb056c71a47ead9fe44ef9cb998beabf). Later he also declared in a comment on LPS-30994 that this method works as intended and it's output in the page source should not be considered a bug.

        Attachments

          Activity

            People

            Assignee:
            support-lep@liferay.com SE Support
            Reporter:
            tibor.jandi Tibor Jandi
            Votes:
            1 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:

                Packages

                Version Package