add_section( 'home_page_hero_option', array( 'title' => __( 'Hero Section Options', 'biziness' ), 'panel' => 'theme_home_option_panel', ) ); $wp_customize->add_setting( 'biziness_options[enable_hero_section]', array( 'default' => $default_options['enable_hero_section'], 'sanitize_callback' => 'biziness_sanitize_checkbox', ) ); $wp_customize->add_control( 'biziness_options[enable_hero_section]', array( 'label' => __( 'Enable Hero Section', 'biziness' ), 'section' => 'home_page_hero_option', 'type' => 'checkbox', ) ); $wp_customize->add_setting( 'biziness_options[hero_post_title]', array( 'default' => $default_options['hero_post_title'], 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( 'biziness_options[hero_post_title]', array( 'label' => __( 'Hero Posts Title', 'biziness' ), 'section' => 'home_page_hero_option', 'type' => 'text', ) ); $wp_customize->add_setting( 'biziness_options[hero_post_description]', array( 'default' => $default_options['hero_post_description'], 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( 'biziness_options[hero_post_description]', array( 'label' => __( 'Hero Posts Description', 'biziness' ), 'section' => 'home_page_hero_option', 'type' => 'textarea', ) ); $wp_customize->add_setting( 'biziness_options[hero_button_text]', array( 'default' => $default_options['hero_button_text'], 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( 'biziness_options[hero_button_text]', array( 'label' => __( 'Hero Button Text', 'biziness' ), 'section' => 'home_page_hero_option', 'type' => 'text', ) ); $wp_customize->add_setting( 'biziness_options[hero_button_url]', array( 'default' => '', 'sanitize_callback' => 'esc_url_raw', ) ); $wp_customize->add_control( 'biziness_options[hero_button_url]', array( 'label' => __( 'Hero Button URL:', 'biziness' ), 'section' => 'home_page_hero_option', 'type' => 'text', 'description' => __( 'Leave empty if you don\'t want the have a this link', 'biziness' ), ) ); $wp_customize->add_setting( 'biziness_options[upload_hero_image]', array( 'default' => '', 'sanitize_callback' => 'biziness_sanitize_image', ) ); $wp_customize->add_control( new WP_Customize_Image_Control( $wp_customize, 'biziness_options[upload_hero_image]', array( 'label' => __( 'Upload Hero Image', 'biziness' ), 'section' => 'home_page_hero_option', ) ) );