The MU forums have moved to WordPress.org

How to remove KSES filtering from posts, but keep it on comments? (4 posts)

  1. ZorkFox
    Member
    Posted 16 years ago #

    I have an installation of WPMU 1.2.4 and would like to disable the KSES filtering of in-line HTML style on posts, but keep it for comments. Do I have to go through that hideous $allowedposttags array in kses.php and add 'style' => array() to all the elements I wish to style, or there a more expedient method? I might be able to do it with grep, but it's chancy, as my regexp writing skills aren't exactly start, if you know what I mean.

    None of my users are hackers, so I feel the potential security risk to visitors is minimal. Leaving the filter in place on comments should keep the majority of malicious persons at bay.

    Does anyone have a suggestion?

  2. ladynada
    Member
    Posted 16 years ago #

  3. donncha
    Key Master
    Posted 16 years ago #

    You should upgrade to 1.2.5a and use the code I posted here to add back the style attribute. Just add "style" to the list of attributes added back in:

    http://ocaoimh.ie/2007/09/10/wordpress-mu-125/

  4. drmiketemp
    Member
    Posted 16 years ago #

    Just as an aside, it's nice to see that some folks aren't afraid to get into the code and make changes.

About this Topic

  • Started 16 years ago by ZorkFox
  • Latest reply from drmiketemp