Home › Forums › Bug Reports › Inline SVG being stripped from backend display › Reply To: Inline SVG being stripped from backend display
Here’s what I heard back from support in case it helps anybody else. It’s not a bug, per se, but related to the newer HTML escaping and now requires a filter, customized to your needs:
ACF 5.10 introduced a new safer escaping system for anything rendered by ACF to prevent XSS attacks, by using WordPress’s kses system.
You can find more information on this here: https://www.advancedcustomfields.com/resources/html-escaping/
Specifically, at the bottom of that article you can see our code snippet you’ll need to add to your theme or plugin in order to allow SVGs inside your markup, as WordPress does not allow them by default.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.