diff --git wp-admin/menu.php wp-admin/menu.php
index 26e8eab..d57136d 100644
|
|
$menu[4] = array( '', 'read', 'separator1', '', 'wp-menu-separator' ); |
49 | 49 | $menu[5] = array( __('Posts'), 'edit_posts', 'edit.php', '', 'open-if-no-js menu-top menu-icon-post', 'menu-posts', 'none' ); |
50 | 50 | $submenu['edit.php'][5] = array( __('All Posts'), 'edit_posts', 'edit.php' ); |
51 | 51 | /* translators: add new post */ |
52 | | $submenu['edit.php'][10] = array( _x('Add New', 'post'), 'edit_posts', 'post-new.php' ); |
| 52 | $submenu['edit.php'][10] = array( _x('Add New', 'post'), 'create_posts', 'post-new.php' ); |
53 | 53 | |
54 | 54 | $i = 15; |
55 | 55 | foreach ( get_taxonomies( array(), 'objects' ) as $tax ) { |
diff --git wp-includes/capabilities.php wp-includes/capabilities.php
index 8252723..e194cb7 100644
|
|
function map_meta_cap( $cap, $user_id ) { |
1046 | 1046 | $caps[] = $post_type->cap->delete_private_posts; |
1047 | 1047 | } |
1048 | 1048 | break; |
| 1049 | // current_user_can( 'create_posts', $post_type ) |
| 1050 | case 'create_posts': |
| 1051 | $post_type = isset( $args[0] ) ? $args[0] : 'post'; |
| 1052 | $post_type_object = get_post_type_object( $post_type ); |
| 1053 | |
| 1054 | $caps[] = $post_type_object->cap->create_posts; |
| 1055 | |
| 1056 | break; |
1049 | 1057 | // edit_post breaks down to edit_posts, edit_published_posts, or |
1050 | 1058 | // edit_others_posts |
1051 | 1059 | case 'edit_post': |
diff --git wp-includes/post.php wp-includes/post.php
index ddf78ab..376132e 100644
|
|
function get_post_type_capabilities( $args ) { |
1296 | 1296 | 'edit_others_posts' => 'edit_others_' . $plural_base, |
1297 | 1297 | 'publish_posts' => 'publish_' . $plural_base, |
1298 | 1298 | 'read_private_posts' => 'read_private_' . $plural_base, |
| 1299 | // Post creation capability simply maps to edit_posts by default: |
| 1300 | 'create_posts' => 'edit_' . $plural_base, |
1299 | 1301 | ); |
1300 | 1302 | |
1301 | 1303 | // Primitive capabilities used within map_meta_cap(): |