Support » Plugins and Hacks » word filter

  • shade

    (@shade)


    I’m calling it decurser 😛 it generally filters out bad words.
    Installation
    1. Download decurser.zip.
    2. Upload decurser.php. Make sure it’s in the same folder as my-hacks.php
    3. Add the following lines to my-hacks.php:
    require_once ‘decurser.php’;
    // filter the posts
    add_filter(‘the_content’,’decurser’);
    // filter the comments
    add_filter(‘comment_text’,’decurser’);

    Done!
    You can configure the words to be filtered in decurser.php and also the filter character. Tell me if there’s any bugs or anything that you might want to add 🙂

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator Matt Mullenweg

    (@matt)

    You should package this as a plugin for 1.2 too.

    carthik

    (@carthik)

    @shade, a look at the existing plugins, such as textile or markdown should give you an idea as to how to pluginize this.

    shade

    (@shade)

    i know how to pluginize this thing. it’s just defining the function and adding the filters, right? it will be done by tomorrow.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.