[wp-hackers] "content_filtered_save_pre" filter?

Viper007Bond viper at viper007bond.com
Sun Sep 9 04:08:14 GMT 2007


I wrote a post and added

add_filter( 'pre_post_content_filtered', 'var_dump' );

to my plugin and after hitting publish, it outputted

string(0) ""

and then a cannot modify headers warning (expected).

Ugh.

On 9/8/07, Ryan Boren <ryan at boren.nu> wrote:
>
> On 9/8/07, Viper007Bond <viper at viper007bond.com> wrote:
> > I want to filter the post before it's inserted into the database
> (reverse
> > some changes TinyMCE makes).
> >
> > According to http://codex.wordpress.org/Plugin_API/Filter_Reference ,
> > "content_filtered_save_pre" appears to be what I want. However, when I
> do
> > this code:
> >
> > add_filter( 'content_filtered_save_pre', 'var_dump' );
> >
> > NULL is outputted, i.e. nothing is being passed to it. I'm using the
> latest
> > SVN.
> >
> > "content_save_pre" gets some data, but it's the raw $_POST with slashes
> > added before quotes and such.
>
> In 2.3, everything gets run through
> sanitize_post()/sanitize_post_field(). pre_post_content_filtered and
> content_filtered_save_pre filters should both be issued. I'm not sure
> why those wouldn't be working.
>
> Ryan
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>



-- 
Viper007Bond | http://www.viper007bond.com/


More information about the wp-hackers mailing list