From 67c8d7f847dff3b933f3a73cac95528e3329267e Mon Sep 17 00:00:00 2001 From: Dominik Schilling Date: Fri, 17 Oct 2014 21:25:19 +0000 Subject: [PATCH] Customizer: Extract content markup for panels to its own method, `WP_Customize_Panel::render_content()`. This allows to override the behavior of a panel, or even to completely replace its contents with something other than controls or sections. props celloexpressions. fixes #29324. Built from https://develop.svn.wordpress.org/trunk@29950 git-svn-id: http://core.svn.wordpress.org/trunk@29699 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/class-wp-customize-panel.php | 50 ++++++++++++++---------- 1 file changed, 30 insertions(+), 20 deletions(-) diff --git a/wp-includes/class-wp-customize-panel.php b/wp-includes/class-wp-customize-panel.php index 8f85049dcb..f289cb7ff0 100644 --- a/wp-includes/class-wp-customize-panel.php +++ b/wp-includes/class-wp-customize-panel.php @@ -162,7 +162,7 @@ class WP_Customize_Panel { } /** - * Render the panel, and the sections that have been added to it. + * Render the panel container, and then its contents. * * @since 4.0.0 * @access protected @@ -175,26 +175,36 @@ class WP_Customize_Panel { +
  • +
    + ' . esc_html( $this->title ) . '' ); + ?> +
    + description ) ) : ?> +
    + description; ?> +
    + +
  • + sections as $section ) { + $section->maybe_render(); + } + } +}