Edit File by line
/home/zeestwma/richards.../wp-inclu...
File: post.php
<?php
[0] Fix | Delete
/**
[1] Fix | Delete
* Core Post API
[2] Fix | Delete
*
[3] Fix | Delete
* @package WordPress
[4] Fix | Delete
* @subpackage Post
[5] Fix | Delete
*/
[6] Fix | Delete
[7] Fix | Delete
//
[8] Fix | Delete
// Post Type registration.
[9] Fix | Delete
//
[10] Fix | Delete
[11] Fix | Delete
/**
[12] Fix | Delete
* Creates the initial post types when 'init' action is fired.
[13] Fix | Delete
*
[14] Fix | Delete
* See {@see 'init'}.
[15] Fix | Delete
*
[16] Fix | Delete
* @since 2.9.0
[17] Fix | Delete
*/
[18] Fix | Delete
function create_initial_post_types() {
[19] Fix | Delete
WP_Post_Type::reset_default_labels();
[20] Fix | Delete
[21] Fix | Delete
register_post_type(
[22] Fix | Delete
'post',
[23] Fix | Delete
array(
[24] Fix | Delete
'labels' => array(
[25] Fix | Delete
'name_admin_bar' => _x( 'Post', 'add new from admin bar' ),
[26] Fix | Delete
),
[27] Fix | Delete
'public' => true,
[28] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[29] Fix | Delete
'_edit_link' => 'post.php?post=%d', /* internal use only. don't use this when registering your own post type. */
[30] Fix | Delete
'capability_type' => 'post',
[31] Fix | Delete
'map_meta_cap' => true,
[32] Fix | Delete
'menu_position' => 5,
[33] Fix | Delete
'menu_icon' => 'dashicons-admin-post',
[34] Fix | Delete
'hierarchical' => false,
[35] Fix | Delete
'rewrite' => false,
[36] Fix | Delete
'query_var' => false,
[37] Fix | Delete
'delete_with_user' => true,
[38] Fix | Delete
'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'excerpt', 'trackbacks', 'custom-fields', 'comments', 'revisions', 'post-formats' ),
[39] Fix | Delete
'show_in_rest' => true,
[40] Fix | Delete
'rest_base' => 'posts',
[41] Fix | Delete
'rest_controller_class' => 'WP_REST_Posts_Controller',
[42] Fix | Delete
)
[43] Fix | Delete
);
[44] Fix | Delete
[45] Fix | Delete
register_post_type(
[46] Fix | Delete
'page',
[47] Fix | Delete
array(
[48] Fix | Delete
'labels' => array(
[49] Fix | Delete
'name_admin_bar' => _x( 'Page', 'add new from admin bar' ),
[50] Fix | Delete
),
[51] Fix | Delete
'public' => true,
[52] Fix | Delete
'publicly_queryable' => false,
[53] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[54] Fix | Delete
'_edit_link' => 'post.php?post=%d', /* internal use only. don't use this when registering your own post type. */
[55] Fix | Delete
'capability_type' => 'page',
[56] Fix | Delete
'map_meta_cap' => true,
[57] Fix | Delete
'menu_position' => 20,
[58] Fix | Delete
'menu_icon' => 'dashicons-admin-page',
[59] Fix | Delete
'hierarchical' => true,
[60] Fix | Delete
'rewrite' => false,
[61] Fix | Delete
'query_var' => false,
[62] Fix | Delete
'delete_with_user' => true,
[63] Fix | Delete
'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'page-attributes', 'custom-fields', 'comments', 'revisions' ),
[64] Fix | Delete
'show_in_rest' => true,
[65] Fix | Delete
'rest_base' => 'pages',
[66] Fix | Delete
'rest_controller_class' => 'WP_REST_Posts_Controller',
[67] Fix | Delete
)
[68] Fix | Delete
);
[69] Fix | Delete
[70] Fix | Delete
register_post_type(
[71] Fix | Delete
'attachment',
[72] Fix | Delete
array(
[73] Fix | Delete
'labels' => array(
[74] Fix | Delete
'name' => _x( 'Media', 'post type general name' ),
[75] Fix | Delete
'name_admin_bar' => _x( 'Media', 'add new from admin bar' ),
[76] Fix | Delete
'add_new' => __( 'Add New Media File' ),
[77] Fix | Delete
'edit_item' => __( 'Edit Media' ),
[78] Fix | Delete
'view_item' => ( '1' === get_option( 'wp_attachment_pages_enabled' ) ) ? __( 'View Attachment Page' ) : __( 'View Media File' ),
[79] Fix | Delete
'attributes' => __( 'Attachment Attributes' ),
[80] Fix | Delete
),
[81] Fix | Delete
'public' => true,
[82] Fix | Delete
'show_ui' => true,
[83] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[84] Fix | Delete
'_edit_link' => 'post.php?post=%d', /* internal use only. don't use this when registering your own post type. */
[85] Fix | Delete
'capability_type' => 'post',
[86] Fix | Delete
'capabilities' => array(
[87] Fix | Delete
'create_posts' => 'upload_files',
[88] Fix | Delete
),
[89] Fix | Delete
'map_meta_cap' => true,
[90] Fix | Delete
'menu_icon' => 'dashicons-admin-media',
[91] Fix | Delete
'hierarchical' => false,
[92] Fix | Delete
'rewrite' => false,
[93] Fix | Delete
'query_var' => false,
[94] Fix | Delete
'show_in_nav_menus' => false,
[95] Fix | Delete
'delete_with_user' => true,
[96] Fix | Delete
'supports' => array( 'title', 'author', 'comments' ),
[97] Fix | Delete
'show_in_rest' => true,
[98] Fix | Delete
'rest_base' => 'media',
[99] Fix | Delete
'rest_controller_class' => 'WP_REST_Attachments_Controller',
[100] Fix | Delete
)
[101] Fix | Delete
);
[102] Fix | Delete
add_post_type_support( 'attachment:audio', 'thumbnail' );
[103] Fix | Delete
add_post_type_support( 'attachment:video', 'thumbnail' );
[104] Fix | Delete
[105] Fix | Delete
register_post_type(
[106] Fix | Delete
'revision',
[107] Fix | Delete
array(
[108] Fix | Delete
'labels' => array(
[109] Fix | Delete
'name' => __( 'Revisions' ),
[110] Fix | Delete
'singular_name' => __( 'Revision' ),
[111] Fix | Delete
),
[112] Fix | Delete
'public' => false,
[113] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[114] Fix | Delete
'_edit_link' => 'revision.php?revision=%d', /* internal use only. don't use this when registering your own post type. */
[115] Fix | Delete
'capability_type' => 'post',
[116] Fix | Delete
'map_meta_cap' => true,
[117] Fix | Delete
'hierarchical' => false,
[118] Fix | Delete
'rewrite' => false,
[119] Fix | Delete
'query_var' => false,
[120] Fix | Delete
'can_export' => false,
[121] Fix | Delete
'delete_with_user' => true,
[122] Fix | Delete
'supports' => array( 'author' ),
[123] Fix | Delete
)
[124] Fix | Delete
);
[125] Fix | Delete
[126] Fix | Delete
register_post_type(
[127] Fix | Delete
'nav_menu_item',
[128] Fix | Delete
array(
[129] Fix | Delete
'labels' => array(
[130] Fix | Delete
'name' => __( 'Navigation Menu Items' ),
[131] Fix | Delete
'singular_name' => __( 'Navigation Menu Item' ),
[132] Fix | Delete
),
[133] Fix | Delete
'public' => false,
[134] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[135] Fix | Delete
'hierarchical' => false,
[136] Fix | Delete
'rewrite' => false,
[137] Fix | Delete
'delete_with_user' => false,
[138] Fix | Delete
'query_var' => false,
[139] Fix | Delete
'map_meta_cap' => true,
[140] Fix | Delete
'capability_type' => array( 'edit_theme_options', 'edit_theme_options' ),
[141] Fix | Delete
'capabilities' => array(
[142] Fix | Delete
// Meta Capabilities.
[143] Fix | Delete
'edit_post' => 'edit_post',
[144] Fix | Delete
'read_post' => 'read_post',
[145] Fix | Delete
'delete_post' => 'delete_post',
[146] Fix | Delete
// Primitive Capabilities.
[147] Fix | Delete
'edit_posts' => 'edit_theme_options',
[148] Fix | Delete
'edit_others_posts' => 'edit_theme_options',
[149] Fix | Delete
'delete_posts' => 'edit_theme_options',
[150] Fix | Delete
'publish_posts' => 'edit_theme_options',
[151] Fix | Delete
'read_private_posts' => 'edit_theme_options',
[152] Fix | Delete
'read' => 'read',
[153] Fix | Delete
'delete_private_posts' => 'edit_theme_options',
[154] Fix | Delete
'delete_published_posts' => 'edit_theme_options',
[155] Fix | Delete
'delete_others_posts' => 'edit_theme_options',
[156] Fix | Delete
'edit_private_posts' => 'edit_theme_options',
[157] Fix | Delete
'edit_published_posts' => 'edit_theme_options',
[158] Fix | Delete
),
[159] Fix | Delete
'show_in_rest' => true,
[160] Fix | Delete
'rest_base' => 'menu-items',
[161] Fix | Delete
'rest_controller_class' => 'WP_REST_Menu_Items_Controller',
[162] Fix | Delete
)
[163] Fix | Delete
);
[164] Fix | Delete
[165] Fix | Delete
register_post_type(
[166] Fix | Delete
'custom_css',
[167] Fix | Delete
array(
[168] Fix | Delete
'labels' => array(
[169] Fix | Delete
'name' => __( 'Custom CSS' ),
[170] Fix | Delete
'singular_name' => __( 'Custom CSS' ),
[171] Fix | Delete
),
[172] Fix | Delete
'public' => false,
[173] Fix | Delete
'hierarchical' => false,
[174] Fix | Delete
'rewrite' => false,
[175] Fix | Delete
'query_var' => false,
[176] Fix | Delete
'delete_with_user' => false,
[177] Fix | Delete
'can_export' => true,
[178] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[179] Fix | Delete
'supports' => array( 'title', 'revisions' ),
[180] Fix | Delete
'capabilities' => array(
[181] Fix | Delete
'delete_posts' => 'edit_theme_options',
[182] Fix | Delete
'delete_post' => 'edit_theme_options',
[183] Fix | Delete
'delete_published_posts' => 'edit_theme_options',
[184] Fix | Delete
'delete_private_posts' => 'edit_theme_options',
[185] Fix | Delete
'delete_others_posts' => 'edit_theme_options',
[186] Fix | Delete
'edit_post' => 'edit_css',
[187] Fix | Delete
'edit_posts' => 'edit_css',
[188] Fix | Delete
'edit_others_posts' => 'edit_css',
[189] Fix | Delete
'edit_published_posts' => 'edit_css',
[190] Fix | Delete
'read_post' => 'read',
[191] Fix | Delete
'read_private_posts' => 'read',
[192] Fix | Delete
'publish_posts' => 'edit_theme_options',
[193] Fix | Delete
),
[194] Fix | Delete
)
[195] Fix | Delete
);
[196] Fix | Delete
[197] Fix | Delete
register_post_type(
[198] Fix | Delete
'customize_changeset',
[199] Fix | Delete
array(
[200] Fix | Delete
'labels' => array(
[201] Fix | Delete
'name' => _x( 'Changesets', 'post type general name' ),
[202] Fix | Delete
'singular_name' => _x( 'Changeset', 'post type singular name' ),
[203] Fix | Delete
'add_new' => __( 'Add New Changeset' ),
[204] Fix | Delete
'add_new_item' => __( 'Add New Changeset' ),
[205] Fix | Delete
'new_item' => __( 'New Changeset' ),
[206] Fix | Delete
'edit_item' => __( 'Edit Changeset' ),
[207] Fix | Delete
'view_item' => __( 'View Changeset' ),
[208] Fix | Delete
'all_items' => __( 'All Changesets' ),
[209] Fix | Delete
'search_items' => __( 'Search Changesets' ),
[210] Fix | Delete
'not_found' => __( 'No changesets found.' ),
[211] Fix | Delete
'not_found_in_trash' => __( 'No changesets found in Trash.' ),
[212] Fix | Delete
),
[213] Fix | Delete
'public' => false,
[214] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[215] Fix | Delete
'map_meta_cap' => true,
[216] Fix | Delete
'hierarchical' => false,
[217] Fix | Delete
'rewrite' => false,
[218] Fix | Delete
'query_var' => false,
[219] Fix | Delete
'can_export' => false,
[220] Fix | Delete
'delete_with_user' => false,
[221] Fix | Delete
'supports' => array( 'title', 'author' ),
[222] Fix | Delete
'capability_type' => 'customize_changeset',
[223] Fix | Delete
'capabilities' => array(
[224] Fix | Delete
'create_posts' => 'customize',
[225] Fix | Delete
'delete_others_posts' => 'customize',
[226] Fix | Delete
'delete_post' => 'customize',
[227] Fix | Delete
'delete_posts' => 'customize',
[228] Fix | Delete
'delete_private_posts' => 'customize',
[229] Fix | Delete
'delete_published_posts' => 'customize',
[230] Fix | Delete
'edit_others_posts' => 'customize',
[231] Fix | Delete
'edit_post' => 'customize',
[232] Fix | Delete
'edit_posts' => 'customize',
[233] Fix | Delete
'edit_private_posts' => 'customize',
[234] Fix | Delete
'edit_published_posts' => 'do_not_allow',
[235] Fix | Delete
'publish_posts' => 'customize',
[236] Fix | Delete
'read' => 'read',
[237] Fix | Delete
'read_post' => 'customize',
[238] Fix | Delete
'read_private_posts' => 'customize',
[239] Fix | Delete
),
[240] Fix | Delete
)
[241] Fix | Delete
);
[242] Fix | Delete
[243] Fix | Delete
register_post_type(
[244] Fix | Delete
'oembed_cache',
[245] Fix | Delete
array(
[246] Fix | Delete
'labels' => array(
[247] Fix | Delete
'name' => __( 'oEmbed Responses' ),
[248] Fix | Delete
'singular_name' => __( 'oEmbed Response' ),
[249] Fix | Delete
),
[250] Fix | Delete
'public' => false,
[251] Fix | Delete
'hierarchical' => false,
[252] Fix | Delete
'rewrite' => false,
[253] Fix | Delete
'query_var' => false,
[254] Fix | Delete
'delete_with_user' => false,
[255] Fix | Delete
'can_export' => false,
[256] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[257] Fix | Delete
'supports' => array(),
[258] Fix | Delete
)
[259] Fix | Delete
);
[260] Fix | Delete
[261] Fix | Delete
register_post_type(
[262] Fix | Delete
'user_request',
[263] Fix | Delete
array(
[264] Fix | Delete
'labels' => array(
[265] Fix | Delete
'name' => __( 'User Requests' ),
[266] Fix | Delete
'singular_name' => __( 'User Request' ),
[267] Fix | Delete
),
[268] Fix | Delete
'public' => false,
[269] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[270] Fix | Delete
'hierarchical' => false,
[271] Fix | Delete
'rewrite' => false,
[272] Fix | Delete
'query_var' => false,
[273] Fix | Delete
'can_export' => false,
[274] Fix | Delete
'delete_with_user' => false,
[275] Fix | Delete
'supports' => array(),
[276] Fix | Delete
)
[277] Fix | Delete
);
[278] Fix | Delete
[279] Fix | Delete
register_post_type(
[280] Fix | Delete
'wp_block',
[281] Fix | Delete
array(
[282] Fix | Delete
'labels' => array(
[283] Fix | Delete
'name' => _x( 'Patterns', 'post type general name' ),
[284] Fix | Delete
'singular_name' => _x( 'Pattern', 'post type singular name' ),
[285] Fix | Delete
'add_new' => __( 'Add New Pattern' ),
[286] Fix | Delete
'add_new_item' => __( 'Add New Pattern' ),
[287] Fix | Delete
'new_item' => __( 'New Pattern' ),
[288] Fix | Delete
'edit_item' => __( 'Edit Block Pattern' ),
[289] Fix | Delete
'view_item' => __( 'View Pattern' ),
[290] Fix | Delete
'view_items' => __( 'View Patterns' ),
[291] Fix | Delete
'all_items' => __( 'All Patterns' ),
[292] Fix | Delete
'search_items' => __( 'Search Patterns' ),
[293] Fix | Delete
'not_found' => __( 'No patterns found.' ),
[294] Fix | Delete
'not_found_in_trash' => __( 'No patterns found in Trash.' ),
[295] Fix | Delete
'filter_items_list' => __( 'Filter patterns list' ),
[296] Fix | Delete
'items_list_navigation' => __( 'Patterns list navigation' ),
[297] Fix | Delete
'items_list' => __( 'Patterns list' ),
[298] Fix | Delete
'item_published' => __( 'Pattern published.' ),
[299] Fix | Delete
'item_published_privately' => __( 'Pattern published privately.' ),
[300] Fix | Delete
'item_reverted_to_draft' => __( 'Pattern reverted to draft.' ),
[301] Fix | Delete
'item_scheduled' => __( 'Pattern scheduled.' ),
[302] Fix | Delete
'item_updated' => __( 'Pattern updated.' ),
[303] Fix | Delete
),
[304] Fix | Delete
'public' => false,
[305] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[306] Fix | Delete
'show_ui' => true,
[307] Fix | Delete
'show_in_menu' => false,
[308] Fix | Delete
'rewrite' => false,
[309] Fix | Delete
'show_in_rest' => true,
[310] Fix | Delete
'rest_base' => 'blocks',
[311] Fix | Delete
'rest_controller_class' => 'WP_REST_Blocks_Controller',
[312] Fix | Delete
'capability_type' => 'block',
[313] Fix | Delete
'capabilities' => array(
[314] Fix | Delete
// You need to be able to edit posts, in order to read blocks in their raw form.
[315] Fix | Delete
'read' => 'edit_posts',
[316] Fix | Delete
// You need to be able to publish posts, in order to create blocks.
[317] Fix | Delete
'create_posts' => 'publish_posts',
[318] Fix | Delete
'edit_posts' => 'edit_posts',
[319] Fix | Delete
'edit_published_posts' => 'edit_published_posts',
[320] Fix | Delete
'delete_published_posts' => 'delete_published_posts',
[321] Fix | Delete
// Enables trashing draft posts as well.
[322] Fix | Delete
'delete_posts' => 'delete_posts',
[323] Fix | Delete
'edit_others_posts' => 'edit_others_posts',
[324] Fix | Delete
'delete_others_posts' => 'delete_others_posts',
[325] Fix | Delete
),
[326] Fix | Delete
'map_meta_cap' => true,
[327] Fix | Delete
'supports' => array(
[328] Fix | Delete
'title',
[329] Fix | Delete
'excerpt',
[330] Fix | Delete
'editor',
[331] Fix | Delete
'revisions',
[332] Fix | Delete
'custom-fields',
[333] Fix | Delete
),
[334] Fix | Delete
)
[335] Fix | Delete
);
[336] Fix | Delete
[337] Fix | Delete
$template_edit_link = 'site-editor.php?' . build_query(
[338] Fix | Delete
array(
[339] Fix | Delete
'postType' => '%s',
[340] Fix | Delete
'postId' => '%s',
[341] Fix | Delete
'canvas' => 'edit',
[342] Fix | Delete
)
[343] Fix | Delete
);
[344] Fix | Delete
[345] Fix | Delete
register_post_type(
[346] Fix | Delete
'wp_template',
[347] Fix | Delete
array(
[348] Fix | Delete
'labels' => array(
[349] Fix | Delete
'name' => _x( 'Templates', 'post type general name' ),
[350] Fix | Delete
'singular_name' => _x( 'Template', 'post type singular name' ),
[351] Fix | Delete
'add_new' => __( 'Add New Template' ),
[352] Fix | Delete
'add_new_item' => __( 'Add New Template' ),
[353] Fix | Delete
'new_item' => __( 'New Template' ),
[354] Fix | Delete
'edit_item' => __( 'Edit Template' ),
[355] Fix | Delete
'view_item' => __( 'View Template' ),
[356] Fix | Delete
'all_items' => __( 'Templates' ),
[357] Fix | Delete
'search_items' => __( 'Search Templates' ),
[358] Fix | Delete
'parent_item_colon' => __( 'Parent Template:' ),
[359] Fix | Delete
'not_found' => __( 'No templates found.' ),
[360] Fix | Delete
'not_found_in_trash' => __( 'No templates found in Trash.' ),
[361] Fix | Delete
'archives' => __( 'Template archives' ),
[362] Fix | Delete
'insert_into_item' => __( 'Insert into template' ),
[363] Fix | Delete
'uploaded_to_this_item' => __( 'Uploaded to this template' ),
[364] Fix | Delete
'filter_items_list' => __( 'Filter templates list' ),
[365] Fix | Delete
'items_list_navigation' => __( 'Templates list navigation' ),
[366] Fix | Delete
'items_list' => __( 'Templates list' ),
[367] Fix | Delete
'item_updated' => __( 'Template updated.' ),
[368] Fix | Delete
),
[369] Fix | Delete
'description' => __( 'Templates to include in your theme.' ),
[370] Fix | Delete
'public' => false,
[371] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[372] Fix | Delete
'_edit_link' => $template_edit_link, /* internal use only. don't use this when registering your own post type. */
[373] Fix | Delete
'has_archive' => false,
[374] Fix | Delete
'show_ui' => false,
[375] Fix | Delete
'show_in_menu' => false,
[376] Fix | Delete
'show_in_rest' => true,
[377] Fix | Delete
'rewrite' => false,
[378] Fix | Delete
'rest_base' => 'templates',
[379] Fix | Delete
'rest_controller_class' => 'WP_REST_Templates_Controller',
[380] Fix | Delete
'autosave_rest_controller_class' => 'WP_REST_Template_Autosaves_Controller',
[381] Fix | Delete
'revisions_rest_controller_class' => 'WP_REST_Template_Revisions_Controller',
[382] Fix | Delete
'late_route_registration' => true,
[383] Fix | Delete
'capability_type' => array( 'template', 'templates' ),
[384] Fix | Delete
'capabilities' => array(
[385] Fix | Delete
'create_posts' => 'edit_theme_options',
[386] Fix | Delete
'delete_posts' => 'edit_theme_options',
[387] Fix | Delete
'delete_others_posts' => 'edit_theme_options',
[388] Fix | Delete
'delete_private_posts' => 'edit_theme_options',
[389] Fix | Delete
'delete_published_posts' => 'edit_theme_options',
[390] Fix | Delete
'edit_posts' => 'edit_theme_options',
[391] Fix | Delete
'edit_others_posts' => 'edit_theme_options',
[392] Fix | Delete
'edit_private_posts' => 'edit_theme_options',
[393] Fix | Delete
'edit_published_posts' => 'edit_theme_options',
[394] Fix | Delete
'publish_posts' => 'edit_theme_options',
[395] Fix | Delete
'read' => 'edit_theme_options',
[396] Fix | Delete
'read_private_posts' => 'edit_theme_options',
[397] Fix | Delete
),
[398] Fix | Delete
'map_meta_cap' => true,
[399] Fix | Delete
'supports' => array(
[400] Fix | Delete
'title',
[401] Fix | Delete
'slug',
[402] Fix | Delete
'excerpt',
[403] Fix | Delete
'editor',
[404] Fix | Delete
'revisions',
[405] Fix | Delete
'author',
[406] Fix | Delete
),
[407] Fix | Delete
)
[408] Fix | Delete
);
[409] Fix | Delete
[410] Fix | Delete
register_post_type(
[411] Fix | Delete
'wp_template_part',
[412] Fix | Delete
array(
[413] Fix | Delete
'labels' => array(
[414] Fix | Delete
'name' => _x( 'Template Parts', 'post type general name' ),
[415] Fix | Delete
'singular_name' => _x( 'Template Part', 'post type singular name' ),
[416] Fix | Delete
'add_new' => __( 'Add New Template Part' ),
[417] Fix | Delete
'add_new_item' => __( 'Add New Template Part' ),
[418] Fix | Delete
'new_item' => __( 'New Template Part' ),
[419] Fix | Delete
'edit_item' => __( 'Edit Template Part' ),
[420] Fix | Delete
'view_item' => __( 'View Template Part' ),
[421] Fix | Delete
'all_items' => __( 'Template Parts' ),
[422] Fix | Delete
'search_items' => __( 'Search Template Parts' ),
[423] Fix | Delete
'parent_item_colon' => __( 'Parent Template Part:' ),
[424] Fix | Delete
'not_found' => __( 'No template parts found.' ),
[425] Fix | Delete
'not_found_in_trash' => __( 'No template parts found in Trash.' ),
[426] Fix | Delete
'archives' => __( 'Template part archives' ),
[427] Fix | Delete
'insert_into_item' => __( 'Insert into template part' ),
[428] Fix | Delete
'uploaded_to_this_item' => __( 'Uploaded to this template part' ),
[429] Fix | Delete
'filter_items_list' => __( 'Filter template parts list' ),
[430] Fix | Delete
'items_list_navigation' => __( 'Template parts list navigation' ),
[431] Fix | Delete
'items_list' => __( 'Template parts list' ),
[432] Fix | Delete
'item_updated' => __( 'Template part updated.' ),
[433] Fix | Delete
),
[434] Fix | Delete
'description' => __( 'Template parts to include in your templates.' ),
[435] Fix | Delete
'public' => false,
[436] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[437] Fix | Delete
'_edit_link' => $template_edit_link, /* internal use only. don't use this when registering your own post type. */
[438] Fix | Delete
'has_archive' => false,
[439] Fix | Delete
'show_ui' => false,
[440] Fix | Delete
'show_in_menu' => false,
[441] Fix | Delete
'show_in_rest' => true,
[442] Fix | Delete
'rewrite' => false,
[443] Fix | Delete
'rest_base' => 'template-parts',
[444] Fix | Delete
'rest_controller_class' => 'WP_REST_Templates_Controller',
[445] Fix | Delete
'autosave_rest_controller_class' => 'WP_REST_Template_Autosaves_Controller',
[446] Fix | Delete
'revisions_rest_controller_class' => 'WP_REST_Template_Revisions_Controller',
[447] Fix | Delete
'late_route_registration' => true,
[448] Fix | Delete
'map_meta_cap' => true,
[449] Fix | Delete
'capabilities' => array(
[450] Fix | Delete
'create_posts' => 'edit_theme_options',
[451] Fix | Delete
'delete_posts' => 'edit_theme_options',
[452] Fix | Delete
'delete_others_posts' => 'edit_theme_options',
[453] Fix | Delete
'delete_private_posts' => 'edit_theme_options',
[454] Fix | Delete
'delete_published_posts' => 'edit_theme_options',
[455] Fix | Delete
'edit_posts' => 'edit_theme_options',
[456] Fix | Delete
'edit_others_posts' => 'edit_theme_options',
[457] Fix | Delete
'edit_private_posts' => 'edit_theme_options',
[458] Fix | Delete
'edit_published_posts' => 'edit_theme_options',
[459] Fix | Delete
'publish_posts' => 'edit_theme_options',
[460] Fix | Delete
'read' => 'edit_theme_options',
[461] Fix | Delete
'read_private_posts' => 'edit_theme_options',
[462] Fix | Delete
),
[463] Fix | Delete
'supports' => array(
[464] Fix | Delete
'title',
[465] Fix | Delete
'slug',
[466] Fix | Delete
'excerpt',
[467] Fix | Delete
'editor',
[468] Fix | Delete
'revisions',
[469] Fix | Delete
'author',
[470] Fix | Delete
),
[471] Fix | Delete
)
[472] Fix | Delete
);
[473] Fix | Delete
[474] Fix | Delete
register_post_type(
[475] Fix | Delete
'wp_global_styles',
[476] Fix | Delete
array(
[477] Fix | Delete
'label' => _x( 'Global Styles', 'post type general name' ),
[478] Fix | Delete
'description' => __( 'Global styles to include in themes.' ),
[479] Fix | Delete
'public' => false,
[480] Fix | Delete
'_builtin' => true, /* internal use only. don't use this when registering your own post type. */
[481] Fix | Delete
'_edit_link' => '/site-editor.php?canvas=edit', /* internal use only. don't use this when registering your own post type. */
[482] Fix | Delete
'show_ui' => false,
[483] Fix | Delete
'show_in_rest' => true,
[484] Fix | Delete
'rewrite' => false,
[485] Fix | Delete
'rest_base' => 'global-styles',
[486] Fix | Delete
'rest_controller_class' => 'WP_REST_Global_Styles_Controller',
[487] Fix | Delete
'revisions_rest_controller_class' => 'WP_REST_Global_Styles_Revisions_Controller',
[488] Fix | Delete
'late_route_registration' => true,
[489] Fix | Delete
'capabilities' => array(
[490] Fix | Delete
'read' => 'edit_theme_options',
[491] Fix | Delete
'create_posts' => 'edit_theme_options',
[492] Fix | Delete
'edit_posts' => 'edit_theme_options',
[493] Fix | Delete
'edit_published_posts' => 'edit_theme_options',
[494] Fix | Delete
'delete_published_posts' => 'edit_theme_options',
[495] Fix | Delete
'edit_others_posts' => 'edit_theme_options',
[496] Fix | Delete
'delete_others_posts' => 'edit_theme_options',
[497] Fix | Delete
),
[498] Fix | Delete
'map_meta_cap' => true,
[499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function