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

Web content URL validator attempts to validate links to pages or documents that are inside comments

    Details

      Description

      Description
      When validating URLs inside of text (such as in a web content article), the validator just grabs any URL it finds inside of an "href" tag and tries to validate it. The problem with this is that the href tag could be inside a comment and thus should not need to be validated.

      Steps to reproduce

      1. Start up Liferay and log in as the admin user
      2. Navigate to Liferay > Content > Web Content > + (Add Button) > Basic Web Content.
      3. Switch the "Content" field to Code view.
      4. Paste the following HTML into the "Content" field.
        <p>This is a test <!--<a href="http://localhost:8080/web/guest/link-to-page-that-does-not-exist">Link</a>--></p>
      5. Click on the Publish button

      Expected Result: The web content article would be published successfully, since it does not contain any problematic links that any user can access when they view the article.
      Actual Result: The article fails to publish with a " The content references a missing page." error.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              lu.liu Lu Liu
              Reporter:
              michael.bowerman Michael Bowerman (Inactive)
              Participants of an Issue:
              Recent user:
              Yunlin "Steven" Sun
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                1 year, 40 weeks, 5 days ago

                  Packages

                  Version Package
                  7.0.0 DXP FP93
                  7.0.10.14 DXP SP14
                  7.0.X
                  7.1.10 DXP FP18
                  7.1.10.5 SP5
                  7.1.X
                  Master