default_page_template_title filter-hookWP 4.1.0

Filters the title of the default page template displayed in the drop-down.

Usage

add_filter( 'default_page_template_title', 'wp_kama_default_page_template_title_filter', 10, 2 );

/**
 * Function for `default_page_template_title` filter-hook.
 * 
 * @param string $label   The display value for the default page template title.
 * @param string $context Where the option label is displayed. Possible values include 'meta-box' or 'quick-edit'.
 *
 * @return string
 */
function wp_kama_default_page_template_title_filter( $label, $context ){

	// filter...
	return $label;
}
$label(string)
The display value for the default page template title.
$context(string)
Where the option label is displayed. Possible values include 'meta-box' or 'quick-edit'.

Changelog

Since 4.1.0 Introduced.

Where the hook is called

page_attributes_meta_box()
default_page_template_title
WP_Posts_List_Table::inline_edit()
default_page_template_title
wp-admin/includes/meta-boxes.php 1004
$default_title = apply_filters( 'default_page_template_title', __( 'Default template' ), 'meta-box' );
wp-admin/edit-form-blocks.php 140
'' => apply_filters( 'default_page_template_title', __( 'Default template' ), 'rest-api' ),
wp-admin/includes/class-wp-posts-list-table.php 1836
$default_title = apply_filters( 'default_page_template_title', __( 'Default template' ), 'quick-edit' );

Where the hook is used in WordPress

Usage not found.