Uploaded image for project: '[Read Only] - Hippo Essentials'
  1. [Read Only] - Hippo Essentials
  2. ESSENTIALS-797

[Forward-port to 10.2/trunk] HippoHtmlAdapter does not rewrite html links

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • 2.0.1
    • 2.2.0
    • None
    • Tiger Sprint 115

    Description

      org.onehippo.cms7.essentials.components.rest.adapters.HippoHtmlAdapter#marshal does not rewrite internal links correctly.

      In this line the html.getNode().getParent() must be replaced with html.getNode().

      final String rewrite = contentRewriter.rewrite(html.getContent(), html.getNode().getParent(), context, context.getResolvedMount().getMount());

      Reproduction path:

      • install project with 3.0.1 archetype
      • add a content feature, e.g. News or Events
      • in the CMS: add an internal link in the rich text field from one document to another
      • use the Rest Services set up tool to create a rest service
      • rebuild, restart
      • retrieve the REST output of the service
      • the href of the link is /site/pagenotfound

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              tjeger Tobias Jeger
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: