→ Adding a Customizer Control Color¶
UPDATE
From here, you’ll move to different advanced control fields which you can add in the WP Customizer.
Let’s create a Color Picker. Type wpC
in the Sublime Text and choose wpCustomizerAddControlColor
.
The WordPress Customizer snippets outputs the following code:
1 2 3 4 5 6 7 8 9 10 11 | <?php // Control: Name. $wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'prefix_id', array( 'label' => __( 'Color Picker!', 'TEXT_DOMAIN' ), 'section' => 'prefix_section_id', 'settings' => 'prefix_id', ) ) ); |