This is kind of a hacky way to accomplish this but digging around core reveals that the default section name is header_image
:
https://core.trac.wordpress.org/browser/tags/3.5.1/wp-includes/class-wp-customize-control.php#L734
So if we name the section we want it added to as header_image
, the custom-header
settings will automatically apply to that section. For example:
$wp_customize->add_panel(
'example_panel',
array(
'priority' => 10,
'capability' => 'edit_theme_options',
'theme_supports' => '',
'title' => __( 'Example Panel', 'textdomain' ),
'description' => __( 'Description of what this panel does.', 'textdomain' ),
)
);
$wp_customize->add_section(
'header_image',
array(
'title' => __( 'Slider Images', 'textdomain' ),
'description' => __( 'This is a section for the slider images.', 'textdomain' ),
'priority' => 10,
'panel' => 'example_panel',
)
);
/* Header Image controls will load here */
The header images controls will display and you can you can continue to add other settings in the panel:
$wp_customize->add_control(
'example_text',
array(
'label' => __( 'Example Text', 'textdomain' ),
'section' => 'header_image',
'type' => 'text',
'panel' => 'example_panel'
)
);