|
@@ 432-439 (lines=8) @@
|
| 429 |
|
return $post; |
| 430 |
|
} |
| 431 |
|
|
| 432 |
|
private function remove_embed() { |
| 433 |
|
global $wp_embed; |
| 434 |
|
remove_filter( 'the_content', array( $wp_embed, 'run_shortcode' ), 8 ); |
| 435 |
|
// remove the embed shortcode since we would do the part later. |
| 436 |
|
remove_shortcode( 'embed' ); |
| 437 |
|
// Attempts to embed all URLs in a post |
| 438 |
|
remove_filter( 'the_content', array( $wp_embed, 'autoembed' ), 8 ); |
| 439 |
|
|
| 440 |
|
} |
| 441 |
|
|
| 442 |
|
private function add_embed() { |
|
@@ 442-449 (lines=8) @@
|
| 439 |
|
|
| 440 |
|
} |
| 441 |
|
|
| 442 |
|
private function add_embed() { |
| 443 |
|
global $wp_embed; |
| 444 |
|
add_filter( 'the_content', array( $wp_embed, 'run_shortcode' ), 8 ); |
| 445 |
|
// Shortcode placeholder for strip_shortcodes() |
| 446 |
|
add_shortcode( 'embed', '__return_false' ); |
| 447 |
|
// Attempts to embed all URLs in a post |
| 448 |
|
add_filter( 'the_content', array( $wp_embed, 'autoembed' ), 8 ); |
| 449 |
|
} |
| 450 |
|
|
| 451 |
|
public function expand_post_ids( $args ) { |
| 452 |
|
$post_ids = $args[0]; |