Skip to content

Add a option to mark TextArea to be safe #877

@williamjmorenor

Description

@williamjmorenor

Hello

I am working in a project that save a HTML template and then must let the user to edit the HTML Markup and then save the edited HTML in the database, I am using the TextArea field to acomplish this task, but I have found that most of the HTML tags are removed in this line:

https://github.com/pallets-eco/wtforms/blob/main/src/wtforms/widgets/core.py#L327

And if a save the form a get a truncated version of the original HTML in the database.

If there a option to mark the textarea_innerhtml as safe? Or this is a feature that can be included in the TextArea field code?

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