In `page_attributes_meta_box()`, add an action, `'page_attributes_meta_box_template'` to allow callbacks to be performed and HTML to be inserted after the title of the Template section.

Props sgrant.	
Fixes #33625.


git-svn-id: https://develop.svn.wordpress.org/trunk@34340 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Scott Taylor 2015-09-20 02:39:31 +00:00
parent a3cb19c52e
commit 2812cc9595
1 changed files with 11 additions and 1 deletions

View File

@ -778,7 +778,17 @@ function page_attributes_meta_box($post) {
if ( 'page' == $post->post_type && 0 != count( get_page_templates( $post ) ) && get_option( 'page_for_posts' ) != $post->ID ) {
$template = !empty($post->page_template) ? $post->page_template : false;
?>
<p><strong><?php _e('Template') ?></strong></p>
<p><strong><?php _e('Template') ?></strong><?php
/**
* Perform actions immediately after displaying the heading for the Template
* section of the Page Attributes meta box.
*
* @since 4.4.0
*
* @param string $template The template used for the current post.
*/
do_action( 'page_attributes_meta_box_template', $template );
?></p>
<label class="screen-reader-text" for="page_template"><?php _e('Page Template') ?></label><select name="page_template" id="page_template">
<?php
/**