Skip to content

Custom template HTML #2615

Description

@mariano-merlo

Describe the bug

In GeoNode 4.4, when enabling "Use a custom template" for the GetFeatureInfo template in the Dataset Metadata Editor, the editor included a "Source Code" button that allowed pasting raw HTML (tables, divs, custom styles, etc.) so it would be rendered as markup in the GetFeatureInfo popup.

Image

Actual Behavior

In GeoNode 5.0.1, the same "Use a custom template" field in the Dataset only shows a editor. There is no "Source Code" toolbar button. When pasting raw HTML directly into the editor, it is escaped and displayed as literal text in the popup instead of being rendered as HTML.

Expected Behavior

Ability to freely generate an identification label using HTML code, in the same way as the MapStore included in GeoNode 4.4.

Steps to Reproduce the Problem

Go to "Map Layer Configuration" in GeoNode 5.0.1, then "Feature Info," and edit the GetFeatureInfo template.
Try pasting a raw HTML code snippet (e.g., a <table> with placeholders like ${properties.<attribute_name>}) directly into the editor.
Save the changes and view the dataset's GetFeatureInfo popup on a map: the HTML tags appear as literal text instead of being rendered, and there is no "Source Code" (<>) button on the editor toolbar to switch to raw HTML input mode.

Image

Specifications

  • GeoNode client version: 5.0.1
  • Browser:
  • Installation type (vanilla, geonode-project): (manual)
  • Additional details:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions