FilamentF
Filament3y ago
3 replies
Isaaaac

How to parse HTML content from rich text editor?

Hello Everyone. Great work!

Suppose I have a rich text editor that save HTML in my database, then I want to display it in a Filament view. How can I parse the HTML so it won't display as an HTML?
image.png
Solution
Hi, you can simply add ->html() to the table column that's description. That way it will render the HTML.

If you don't need that, you can modify the column value to add strip_tags() as that will remove all html tags and leave the text in
Was this page helpful?