Bug #2941

wordpress content filtering

Added by Keith Miyake almost 8 years ago. Updated almost 8 years ago.

Priority name:
Category name:
Target version:
Start date:
Due date:
% Done:


Estimated time:


Wordpress is filtering content from pages/posts including some advanced css styles (such as box-shadow) and all <script> tags. Is it possible to disable this filtering or otherwise allow custom javascript to be included within a page? Not a big issue as I can modify the theme directly, but it is nice to have the flexibility to just do some quick edits from within a page's content.

FWIW, I'm only using the text editing mode and not the visual editor, and the post content works fine (isn't filtered) on my local instance.



#1 Updated by Boone Gorges almost 8 years ago

  • Status changed from New to Rejected

Hi Keith. The filtering you've experienced is a security precaution. We only allow a subset of CSS and no JS inline in posts, because either of these items could be used for various XSS attacks. (You probably didn't see this in your local installation because it only kicks in automatically when Multisite is activated.) I'm afraid it won't be possible to lift the restrictions globally. It may be possible for me to do so on a local basis, but since you are providing me with a theme anyway, I think it's easiest if you put it into the theme files.

Also available in: Atom PDF