Tag Info

New answers tagged

0

Let's go and see what would core do. In default-filters.php here is what content output passes through: add_filter( 'the_content', 'wptexturize' ); add_filter( 'the_content', 'convert_smilies' ); add_filter( 'the_content', 'convert_chars' ); add_filter( 'the_content', 'wpautop' ); add_filter( 'the_content', 'shortcode_unautop' ); ...


1

And the strange part: both codes echo the same string for $url!!! No, they don't. Look at the page source. esc_url() is encoding the & control character. You can't do that and expect the HTTP request to work correctly. Use esc_url_raw() instead. Note the description in the Codex concerning that function: The esc_url_raw() function is similar to ...


0

I'm not sure how WP's admin interface handles this (e.g. the scenario I referenced in the question), but I found a way to accomplish this: //Disable KSES kses_remove_filters(); $update_rval = wp_update_post($updates); //Reenable KSES kses_init_filters(); Note that "kses" functions are part of Wordpress' defense against evil code. So, use this ...



Top 50 recent answers are included