Editor: Display Rich Text in Datatable

Editor: Display Rich Text in Datatable

kmboninkmbonin Posts: 59Questions: 16Answers: 0

I have a datatable that I am using TinyMCE for formatting a textarea that will display alerts to users on the home page of my web app. This is working well, but when I display the rich text in the Alerts -> Manage Alerts page with a datatable on it, it shows the HTML instead of rendering it. Assuming I'm missing a class/className or render property, but I cannot find what the value should be. Image below:

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 61,824Questions: 1Answers: 10,131 Site admin

    This is probably caused by the XSS protection that is built into the Editor server-side libraries. If you are happy to allow scripting, you can disable that option.

    Allan

  • kmboninkmbonin Posts: 59Questions: 16Answers: 0

    Added .Xss(false) to the .Field definition in my controller, but it's still rendering it as text in the datatable.

  • allanallan Posts: 61,824Questions: 1Answers: 10,131 Site admin
    Answer ✓

    Did you resave the information to the database? It is saved in its "safe" state, so it would need to be rerendered and saved again in its "unsafe" state.

    Allan

  • kmboninkmbonin Posts: 59Questions: 16Answers: 0

    Of course I didn't do that. :) Works now. Thanks!!!

This discussion has been closed.