add_setting( 'Date_display', array( 'default' => 'hide', 'sanitize_callback' => 'postmag_sanitize_radio' ) ); $wp_customize->add_control( 'Date_display', array( 'label' => __( 'Date Display', 'postmag' ), 'section' => 'title_tagline', 'settings' => 'Date_display', 'type' => 'radio', 'choices' => array( 'show' => __( 'Show Date', 'postmag' ), 'hide' => __( 'Hide Date', 'postmag' ), ), ) ); $wp_customize->add_section( 'scratch_post_section', array( 'title' => __( 'Post setting', 'postmag' ), 'priority' => 20, ) ); // first control $wp_customize->add_setting( 'post_date_display', array( 'default' => 'show', 'transport' => 'refresh', 'sanitize_callback' => 'postmag_sanitize_radio' ) ); $wp_customize->add_control( 'post_date_display', array( 'label' => __( 'Post Date Display', 'postmag' ), 'section' => 'scratch_post_section', 'settings' => 'post_date_display', 'type' => 'radio', 'choices' => array( 'show' => __( 'Show Date', 'postmag' ), 'hide' => __( 'Hide Date', 'postmag' ), ), ) ); $wp_customize->add_setting( 'post_comment_display', array( 'default' => 'show', 'transport' => 'refresh', 'sanitize_callback' => 'postmag_sanitize_radio' ) ); $wp_customize->add_control( 'post_comment_display', array( 'label' => __( 'Post Comment Display', 'postmag' ), 'section' => 'scratch_post_section', 'settings' => 'post_comment_display', 'type' => 'radio', 'choices' => array( 'show' => __( 'Show Comments', 'postmag' ), 'hide' => __( 'Hide Comments', 'postmag' ), ), ) ); $wp_customize->add_section( 'scratch_buy_section', array( 'title' => __( 'Buy Pro', 'postmag' ), 'priority' => 20, ) ); } add_action( 'customize_register', 'postmag_customize_other' );