Skip to:
Content

BuddyPress.org

Ticket #362: add_pre_post.patch

File add_pre_post.patch, 672 bytes (added by burtadsit, 16 years ago)

bbpress pre post encoded data filter

  • buddypress-enable.php

     
    88Author URI: http://apeatling.wordpress.com/
    99*/
    1010
     11function for_buddypress_pre_post($post_text, $post_id, $topic_id){
     12        $post_text = stripslashes(stripslashes_deep($post_text));
     13        $post_text = str_replace( '/amp/', '&', $post_text );
     14        $post_text = html_entity_decode( $post_text, ENT_COMPAT, "UTF-8" );
     15
     16        return $post_text;
     17}
     18add_filter( 'pre_post', 'for_buddypress_pre_post',10,3);
     19
    1120function for_buddypress_strip_tags( $_post, $post ) {
    1221       
    1322        // Cast to an array