mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 09:37:42 +01:00
Pass the default post to default_content, default_title, and default_excerpt filters. Allows filtering by post_type and other attributes. see #9674
git-svn-id: http://svn.automattic.com/wordpress/trunk@13051 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
98c0c1065b
commit
534e797399
@ -374,9 +374,9 @@ function get_default_post_to_edit( $post_type = 'post', $create_in_db = false )
|
||||
$post->menu_order = 0;
|
||||
}
|
||||
|
||||
$post->post_content = apply_filters( 'default_content', $post_content );
|
||||
$post->post_title = apply_filters( 'default_title', $post_title );
|
||||
$post->post_excerpt = apply_filters( 'default_excerpt', $post_excerpt );
|
||||
$post->post_content = apply_filters( 'default_content', $post_content, $post );
|
||||
$post->post_title = apply_filters( 'default_title', $post_title, $post );
|
||||
$post->post_excerpt = apply_filters( 'default_excerpt', $post_excerpt, $post );
|
||||
$post->post_name = '';
|
||||
|
||||
return $post;
|
||||
|
Loading…
Reference in New Issue
Block a user