add_section( 'adventure_trekking_camp_typography_settings', array( 'title' => __( 'Typography', 'adventure-trekking-camp' ), 'priority' => 2, ) ); $adventure_trekking_camp_font_choices = array( '' => 'Select', 'Source Sans Pro:400,700,400italic,700italic' => 'Source Sans Pro', 'Open Sans:400italic,700italic,400,700' => 'Open Sans', 'Oswald:400,700' => 'Oswald', 'Playfair Display:400,700,400italic' => 'Playfair Display', 'Montserrat:400,700' => 'Montserrat', 'Raleway:400,700' => 'Raleway', 'Droid Sans:400,700' => 'Droid Sans', 'Lato:400,700,400italic,700italic' => 'Lato', 'Arvo:400,700,400italic,700italic' => 'Arvo', 'Lora:400,700,400italic,700italic' => 'Lora', 'Merriweather:400,300italic,300,400italic,700,700italic' => 'Merriweather', 'Oxygen:400,300,700' => 'Oxygen', 'PT Serif:400,700' => 'PT Serif', 'PT Sans:400,700,400italic,700italic' => 'PT Sans', 'PT Sans Narrow:400,700' => 'PT Sans Narrow', 'Cabin:400,700,400italic' => 'Cabin', 'Fjalla One:400' => 'Fjalla One', 'Francois One:400' => 'Francois One', 'Josefin Sans:400,300,600,700' => 'Josefin Sans', 'Libre Baskerville:400,400italic,700' => 'Libre Baskerville', 'Arimo:400,700,400italic,700italic' => 'Arimo', 'Ubuntu:400,700,400italic,700italic' => 'Ubuntu', 'Bitter:400,700,400italic' => 'Bitter', 'Droid Serif:400,700,400italic,700italic' => 'Droid Serif', 'Roboto:400,400italic,700,700italic' => 'Roboto', 'Open Sans Condensed:700,300italic,300' => 'Open Sans Condensed', 'Roboto Condensed:400italic,700italic,400,700' => 'Roboto Condensed', 'Roboto Slab:400,700' => 'Roboto Slab', 'Yanone Kaffeesatz:400,700' => 'Yanone Kaffeesatz', 'Rokkitt:400' => 'Rokkitt', ); $wp_customize->add_setting( 'adventure_trekking_camp_section_typo_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_typo_heading', array( 'label' => esc_html__( 'Typography Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_typography_settings', 'settings' => 'adventure_trekking_camp_section_typo_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_headings_text', array( 'sanitize_callback' => 'adventure_trekking_camp_sanitize_fonts', )); $wp_customize->add_control( 'adventure_trekking_camp_headings_text', array( 'type' => 'select', 'description' => __('Select your suitable font for the headings.', 'adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_typography_settings', 'choices' => $adventure_trekking_camp_font_choices )); $wp_customize->add_setting( 'adventure_trekking_camp_body_text', array( 'sanitize_callback' => 'adventure_trekking_camp_sanitize_fonts' )); $wp_customize->add_control( 'adventure_trekking_camp_body_text', array( 'type' => 'select', 'description' => __( 'Select your suitable font for the body.', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_typography_settings', 'choices' => $adventure_trekking_camp_font_choices ) ); $wp_customize->add_section('adventure_trekking_camp_pro', array( 'title' => __('UPGRADE TREKKING CAMP PREMIUM', 'adventure-trekking-camp'), 'priority' => 1, )); $wp_customize->add_setting('adventure_trekking_camp_pro', array( 'default' => null, 'sanitize_callback' => 'sanitize_text_field', )); $wp_customize->add_control(new Adventure_Trekking_Camp_Pro_Control($wp_customize, 'adventure_trekking_camp_pro', array( 'label' => __('TREKKING CAMP PREMIUM', 'adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_pro', 'settings' => 'adventure_trekking_camp_pro', 'priority' => 1, ))); //Logo $wp_customize->add_setting('adventure_trekking_camp_logo_max_height',array( 'default'=> '100', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_integer' )); $wp_customize->add_control(new Adventure_Trekking_Camp_Slider_Custom_Control( $wp_customize, 'adventure_trekking_camp_logo_max_height',array( 'label' => esc_html__('Logo Width','adventure-trekking-camp'), 'section'=> 'title_tagline', 'settings'=>'adventure_trekking_camp_logo_max_height', 'input_attrs' => array( 'reset' => 100, 'step' => 1, 'min' => 0, 'max' => 250, ), ))); $wp_customize->add_setting('adventure_trekking_camp_logo_title', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_logo_title', array( 'settings' => 'adventure_trekking_camp_logo_title', 'section' => 'title_tagline', 'label' => __( 'Show Site Title', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_logo_text', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => 'off', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_logo_text', array( 'settings' => 'adventure_trekking_camp_logo_text', 'section' => 'title_tagline', 'label' => __( 'Show Site Tagline', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); // Theme General Settings $wp_customize->add_section('adventure_trekking_camp_theme_settings',array( 'title' => __('Theme General Settings', 'adventure-trekking-camp'), 'priority' => 2, ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_sticky_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_sticky_heading', array( 'label' => esc_html__( 'Sticky Header Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_theme_settings', 'settings' => 'adventure_trekking_camp_section_sticky_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_sticky_header', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => 'off', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_sticky_header', array( 'settings' => 'adventure_trekking_camp_sticky_header', 'section' => 'adventure_trekking_camp_theme_settings', 'label' => __( 'Show Sticky Header', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_loader_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_loader_heading', array( 'label' => esc_html__( 'Loader Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_theme_settings', 'settings' => 'adventure_trekking_camp_section_loader_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_theme_loader', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => 'off', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_theme_loader', array( 'settings' => 'adventure_trekking_camp_theme_loader', 'section' => 'adventure_trekking_camp_theme_settings', 'label' => __( 'Show Site Loader', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_menu_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_menu_heading', array( 'label' => esc_html__( 'Menu Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_theme_settings', 'settings' => 'adventure_trekking_camp_section_menu_heading', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_menu_text_transform',array( 'default' => 'CAPITALISE', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_choices' )); $wp_customize->add_control('adventure_trekking_camp_menu_text_transform',array( 'type' => 'select', 'label' => __('Menus Text Transform','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_theme_settings', 'choices' => array( 'CAPITALISE' => __('CAPITALISE','adventure-trekking-camp'), 'UPPERCASE' => __('UPPERCASE','adventure-trekking-camp'), 'LOWERCASE' => __('LOWERCASE','adventure-trekking-camp'), ), ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_scroll_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_scroll_heading', array( 'label' => esc_html__( 'Scroll Top Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_theme_settings', 'settings' => 'adventure_trekking_camp_section_scroll_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_scroll_enable', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_scroll_enable', array( 'settings' => 'adventure_trekking_camp_scroll_enable', 'section' => 'adventure_trekking_camp_theme_settings', 'label' => __( 'show Scroll Top', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_scroll_options',array( 'default' => 'right_align', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_choices' )); $wp_customize->add_control('adventure_trekking_camp_scroll_options',array( 'type' => 'select', 'label' => __('Scroll Top Alignment','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_theme_settings', 'choices' => array( 'right_align' => __('Right Align','adventure-trekking-camp'), 'center_align' => __('Center Align','adventure-trekking-camp'), 'left_align' => __('Left Align','adventure-trekking-camp'), ), ) ); $wp_customize->add_section('adventure_trekking_camp_breadcrumb_settings',array( 'title' => __('Breadcrumb', 'adventure-trekking-camp'), 'priority' => 2 ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_breadcrumb_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_breadcrumb_heading', array( 'label' => esc_html__( 'Breadcrumb Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_breadcrumb_settings', 'settings' => 'adventure_trekking_camp_section_breadcrumb_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_enable_breadcrumb', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_enable_breadcrumb', array( 'settings' => 'adventure_trekking_camp_enable_breadcrumb', 'section' => 'adventure_trekking_camp_breadcrumb_settings', 'label' => __( 'Show Breadcrumb', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); if ( class_exists( 'WooCommerce' ) ) { $wp_customize->add_section('adventure_trekking_camp_Woocoomerce_settings',array( 'title' => __('WooCommerce Settings', 'adventure-trekking-camp'), 'priority' => 2, ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_shoppage_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_shoppage_heading', array( 'label' => esc_html__( 'Sidebar Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'settings' => 'adventure_trekking_camp_section_shoppage_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_shop_page_sidebar', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_shop_page_sidebar', array( 'settings' => 'adventure_trekking_camp_shop_page_sidebar', 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'label' => __( 'Show Shop Page Sidebar', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_wocommerce_single_page_sidebar', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_wocommerce_single_page_sidebar', array( 'settings' => 'adventure_trekking_camp_wocommerce_single_page_sidebar', 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'label' => __( 'Show Single Product Page Sidebar', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_archieve_product_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_archieve_product_heading', array( 'label' => esc_html__( 'Archieve Product Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'settings' => 'adventure_trekking_camp_section_archieve_product_heading', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_archieve_item_columns',array( 'default' => '3', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_choices' )); $wp_customize->add_control('adventure_trekking_camp_archieve_item_columns',array( 'type' => 'select', 'label' => __('Select No of Columns','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'choices' => array( '1' => __('One Column','adventure-trekking-camp'), '2' => __('Two Column','adventure-trekking-camp'), '3' => __('Three Column','adventure-trekking-camp'), '4' => __('four Column','adventure-trekking-camp'), '5' => __('Five Column','adventure-trekking-camp'), '6' => __('Six Column','adventure-trekking-camp'), ), ) ); $wp_customize->add_setting( 'adventure_trekking_camp_archieve_shop_perpage', array( 'default' => 6, 'type' => 'theme_mod', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_number_absint', 'sanitize_js_callback' => 'absint', ) ); $wp_customize->add_control( 'adventure_trekking_camp_archieve_shop_perpage', array( 'label' => esc_html__( 'Display Products','adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'type' => 'number', 'input_attrs' => array( 'step' => 1, 'min' => 0, 'max' => 30, ), ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_related_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_related_heading', array( 'label' => esc_html__( 'Related Product Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'settings' => 'adventure_trekking_camp_section_related_heading', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_related_item_columns',array( 'default' => '3', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_choices' )); $wp_customize->add_control('adventure_trekking_camp_related_item_columns',array( 'type' => 'select', 'label' => __('Select No of Columns','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'choices' => array( '1' => __('One Column','adventure-trekking-camp'), '2' => __('Two Column','adventure-trekking-camp'), '3' => __('Three Column','adventure-trekking-camp'), '4' => __('four Column','adventure-trekking-camp'), '5' => __('Five Column','adventure-trekking-camp'), '6' => __('Six Column','adventure-trekking-camp'), ), ) ); $wp_customize->add_setting( 'adventure_trekking_camp_related_shop_perpage', array( 'default' => 3, 'type' => 'theme_mod', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_number_absint', 'sanitize_js_callback' => 'absint', ) ); $wp_customize->add_control( 'adventure_trekking_camp_related_shop_perpage', array( 'label' => esc_html__( 'Display Products','adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'type' => 'number', 'input_attrs' => array( 'step' => 1, 'min' => 0, 'max' => 10, ), ) ); $wp_customize->add_setting( 'adventure_trekking_camp_related_product', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch($wp_customize,'adventure_trekking_camp_related_product', array( 'settings' => 'adventure_trekking_camp_related_product', 'section' => 'adventure_trekking_camp_Woocoomerce_settings', 'label' => __( 'Show Related Products', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) )); } //button $wp_customize->add_section('adventure_trekking_camp_button_options',array( 'title' => __('Button settings', 'adventure-trekking-camp'), 'priority' => 2, ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_theme_button_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_theme_button_heading', array( 'label' => esc_html__( 'Theme Button Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_button_options', 'settings' => 'adventure_trekking_camp_section_theme_button_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_theme_button_color', array( 'default' => '', 'sanitize_callback' => 'sanitize_hex_color' )); $wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'adventure_trekking_camp_theme_button_color', array( 'label' => esc_html__( 'Background Color','adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_button_options', 'settings' => 'adventure_trekking_camp_theme_button_color', ))); $wp_customize->add_setting('adventure_trekking_camp_button_border_radius',array( 'default'=> 30, 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_integer' )); $wp_customize->add_control(new Adventure_Trekking_Camp_Slider_Custom_Control( $wp_customize, 'adventure_trekking_camp_button_border_radius',array( 'label' => esc_html__( 'Border Radius','adventure-trekking-camp' ), 'section'=> 'adventure_trekking_camp_button_options', 'settings'=>'adventure_trekking_camp_button_border_radius', 'input_attrs' => array( 'reset' => 30, 'step' => 1, 'min' => 0, 'max' => 30, ), ))); // Post Layouts $wp_customize->add_section('adventure_trekking_camp_layout',array( 'title' => __('Post Layout', 'adventure-trekking-camp'), 'priority' => 2 ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_post_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_post_heading', array( 'label' => esc_html__( 'Post Structure', 'adventure-trekking-camp' ), 'description' => __( 'Change the post layout from below options', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_layout', 'settings' => 'adventure_trekking_camp_section_post_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_single_post_option', array( 'default' => 'single_right_sidebar', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field' ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Radio_Image_Control( $wp_customize, 'adventure_trekking_camp_single_post_option', array( 'type'=>'select', 'label' => __( 'select Single Post Page Layout', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_layout', 'choices' => array( 'single_right_sidebar' => array( 'image' => get_template_directory_uri().'/assets/image/2column.jpg', 'name' => __( 'Right Sidebar', 'adventure-trekking-camp' ) ), 'single_left_sidebar' => array( 'image' => get_template_directory_uri().'/assets/image/left.png', 'name' => __( 'Left Sidebar', 'adventure-trekking-camp' ) ), 'single_full_width' => array( 'image' => get_template_directory_uri().'/assets/image/1column.jpg', 'name' => __( 'One Column', 'adventure-trekking-camp' ) ), ) ) ) ); $wp_customize->add_setting('adventure_trekking_camp_single_post_date', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new adventure_trekking_camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_single_post_date', array( 'settings' => 'adventure_trekking_camp_single_post_date', 'section' => 'adventure_trekking_camp_layout', 'label' => __( 'Show Date', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->selective_refresh->add_partial( 'adventure_trekking_camp_single_post_date', array( 'selector' => '.date-box', 'render_callback' => 'adventure_trekking_camp_customize_partial_adventure_trekking_camp_single_post_date', ) ); $wp_customize->add_setting('adventure_trekking_camp_single_post_admin', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new adventure_trekking_camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_single_post_admin', array( 'settings' => 'adventure_trekking_camp_single_post_admin', 'section' => 'adventure_trekking_camp_layout', 'label' => __( 'Show Author/Admin', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->selective_refresh->add_partial( 'adventure_trekking_camp_single_post_admin', array( 'selector' => '.entry-author', 'render_callback' => 'adventure_trekking_camp_customize_partial_adventure_trekking_camp_single_post_admin', ) ); $wp_customize->add_setting('adventure_trekking_camp_single_post_comment', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new adventure_trekking_camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_single_post_comment', array( 'settings' => 'adventure_trekking_camp_single_post_comment', 'section' => 'adventure_trekking_camp_layout', 'label' => __( 'Show Comment', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_archive_post_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_archive_post_heading', array( 'label' => esc_html__( 'Archieve Post Structure', 'adventure-trekking-camp' ), 'description' => __( 'Change the post layout from below options', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_layout', 'settings' => 'adventure_trekking_camp_section_archive_post_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_post_option', array( 'default' => 'right_sidebar', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field' ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Radio_Image_Control( $wp_customize, 'adventure_trekking_camp_post_option', array( 'type'=>'select', 'label' => __( 'select Post Page Layout', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_layout', 'choices' => array( 'right_sidebar' => array( 'image' => get_template_directory_uri().'/assets/image/2column.jpg', 'name' => __( 'Right Sidebar', 'adventure-trekking-camp' ) ), 'left_sidebar' => array( 'image' => get_template_directory_uri().'/assets/image/left.png', 'name' => __( 'Left Sidebar', 'adventure-trekking-camp' ) ), 'one_column' => array( 'image' => get_template_directory_uri().'/assets/image/1column.jpg', 'name' => __( 'One Column', 'adventure-trekking-camp' ) ), 'three_column' => array( 'image' => get_template_directory_uri().'/assets/image/3column.jpg', 'name' => __( 'Three Column', 'adventure-trekking-camp' ) ), 'four_column' => array( 'image' => get_template_directory_uri().'/assets/image/4column.jpg', 'name' => __( 'Four Column', 'adventure-trekking-camp' ) ), 'grid_sidebar' => array( 'image' => get_template_directory_uri().'/assets/image/grid-sidebar.jpg', 'name' => __( 'Grid-Sidebar Layout', 'adventure-trekking-camp' ) ), 'grid_left_sidebar' => array( 'image' => get_template_directory_uri().'/assets/image/grid-left.png', 'name' => __( 'Grid-Sidebar Layout', 'adventure-trekking-camp' ) ), 'grid_post' => array( 'image' => get_template_directory_uri().'/assets/image/grid.jpg', 'name' => __( 'Grid Layout', 'adventure-trekking-camp' ) ) ) ) ) ); $wp_customize->add_setting('adventure_trekking_camp_grid_column',array( 'default' => '3_column', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_select' )); $wp_customize->add_control('adventure_trekking_camp_grid_column',array( 'label' => esc_html__('Grid Post Per Row','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_layout', 'setting' => 'adventure_trekking_camp_grid_column', 'type' => 'radio', 'choices' => array( '1_column' => __('1','adventure-trekking-camp'), '2_column' => __('2','adventure-trekking-camp'), '3_column' => __('3','adventure-trekking-camp'), '4_column' => __('4','adventure-trekking-camp'), '5_column' => __('6','adventure-trekking-camp'), ), )); $wp_customize->add_setting('adventure_trekking_camp_date', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_date', array( 'settings' => 'adventure_trekking_camp_date', 'section' => 'adventure_trekking_camp_layout', 'label' => __( 'show Date', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->selective_refresh->add_partial( 'adventure_trekking_camp_date', array( 'selector' => '.date-box', 'render_callback' => 'adventure_trekking_camp_customize_partial_adventure_trekking_camp_date', ) ); $wp_customize->add_setting('adventure_trekking_camp_admin', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_admin', array( 'settings' => 'adventure_trekking_camp_admin', 'section' => 'adventure_trekking_camp_layout', 'label' => __( 'show Author/Admin', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->selective_refresh->add_partial( 'adventure_trekking_camp_admin', array( 'selector' => '.entry-author', 'render_callback' => 'adventure_trekking_camp_customize_partial_adventure_trekking_camp_admin', ) ); $wp_customize->add_setting('adventure_trekking_camp_comment', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '1', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control(new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_comment', array( 'settings' => 'adventure_trekking_camp_comment', 'section' => 'adventure_trekking_camp_layout', 'label' => __( 'show Comment', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->selective_refresh->add_partial( 'adventure_trekking_camp_comment', array( 'selector' => '.entry-comments', 'render_callback' => 'adventure_trekking_camp_customize_partial_adventure_trekking_camp_comment', ) ); // Header $wp_customize->add_section('adventure_trekking_camp_header',array( 'title' => __('Header', 'adventure-trekking-camp'), 'priority' => 3 ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_contact_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_contact_heading', array( 'label' => esc_html__( 'Header Settings', 'adventure-trekking-camp' ), 'description' => __( 'Add header information in the below feilds', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_header', 'settings' => 'adventure_trekking_camp_section_contact_heading', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_location_text',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_location_text',array( 'label' => esc_html__('Location Text','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_header', 'setting' => 'adventure_trekking_camp_location_text', 'type' => 'text' )); $wp_customize->add_setting('adventure_trekking_camp_location_address',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_location_address',array( 'label' => esc_html__('Location Adreess','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_header', 'setting' => 'adventure_trekking_camp_location_address', 'type' => 'text' )); $wp_customize->add_setting('adventure_trekking_camp_button_text',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_button_text',array( 'label' => esc_html__('Button Text','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_header', 'setting' => 'adventure_trekking_camp_button_text', 'type' => 'text' )); $wp_customize->add_setting('adventure_trekking_camp_button_link',array( 'default' => '', 'sanitize_callback' => 'esc_url_raw' )); $wp_customize->add_control('adventure_trekking_camp_button_link',array( 'label' => esc_html__('Button Link','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_header', 'setting' => 'adventure_trekking_camp_button_link', 'type' => 'url' )); $wp_customize->add_setting('adventure_trekking_camp_call_text',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_call_text',array( 'label' => esc_html__('Call Text','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_header', 'setting' => 'adventure_trekking_camp_call_text', 'type' => 'text' )); $wp_customize->add_setting('adventure_trekking_camp_call_phone_number',array( 'default' => '', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_phone_number' )); $wp_customize->add_control('adventure_trekking_camp_call_phone_number',array( 'label' => esc_html__('Phone Number','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_header', 'setting' => 'adventure_trekking_camp_call_phone_number', 'type' => 'text' )); //Slider $wp_customize->add_section( 'adventure_trekking_camp_slider_section' , array( 'title' => __( 'Slider Settings', 'adventure-trekking-camp' ), 'priority' => 3, ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_slide_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_slide_heading', array( 'label' => esc_html__( 'Slider Settings', 'adventure-trekking-camp' ), 'description' => __( 'Slider Image Dimension ( 1600px x 650px )', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_slider_section', 'settings' => 'adventure_trekking_camp_section_slide_heading', 'priority'=> 1, ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_slider_arrows', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_slider_arrows', array( 'settings' => 'adventure_trekking_camp_slider_arrows', 'section' => 'adventure_trekking_camp_slider_section', 'label' => __( 'Check To show Slider', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', 'priority' => 1, ) ) ); $wp_customize->add_setting('adventure_trekking_camp_slider_counter',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_slider_counter',array( 'label' => esc_html__('Slider Increament','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_slider_section', 'type' => 'number', 'input_attrs' => array( 'step' => 1, 'min' => 0, 'max' => 3, ), 'active_callback' => 'adventure_trekking_camp_slider_dropdown', )); $adventure_trekking_camp_slider = get_theme_mod('adventure_trekking_camp_slider_counter'); for ($adventure_trekking_camp_i=1; $adventure_trekking_camp_i <= $adventure_trekking_camp_slider ; $adventure_trekking_camp_i++) { $wp_customize->add_setting( 'adventure_trekking_camp_slider_images'.$adventure_trekking_camp_i, array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'esc_url_raw' )); $wp_customize->add_control( new WP_Customize_Image_Control( $wp_customize, 'adventure_trekking_camp_slider_images'.$adventure_trekking_camp_i, array( 'label' => esc_html__('Slider Image ','adventure-trekking-camp').$adventure_trekking_camp_i, 'section' => 'adventure_trekking_camp_slider_section', 'active_callback' => 'adventure_trekking_camp_slider_dropdown', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_slider_sub_heading'.$adventure_trekking_camp_i,array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_slider_sub_heading'.$adventure_trekking_camp_i,array( 'label' => esc_html__('Slider Sub Title ','adventure-trekking-camp').$adventure_trekking_camp_i, 'section' => 'adventure_trekking_camp_slider_section', 'type' => 'text', 'active_callback' => 'adventure_trekking_camp_slider_dropdown', )); $wp_customize->add_setting('adventure_trekking_camp_slider_main_heading'.$adventure_trekking_camp_i,array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_slider_main_heading'.$adventure_trekking_camp_i,array( 'label' => esc_html__('Slider Title ','adventure-trekking-camp').$adventure_trekking_camp_i, 'section' => 'adventure_trekking_camp_slider_section', 'type' => 'text', 'active_callback' => 'adventure_trekking_camp_slider_dropdown', )); $wp_customize->add_setting('adventure_trekking_camp_slider_button_text'.$adventure_trekking_camp_i,array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_slider_button_text'.$adventure_trekking_camp_i,array( 'label' => esc_html__('Slider Button Text ','adventure-trekking-camp').$adventure_trekking_camp_i, 'section' => 'adventure_trekking_camp_slider_section', 'type' => 'text', 'active_callback' => 'adventure_trekking_camp_slider_dropdown', )); $wp_customize->add_setting('adventure_trekking_camp_slider_button_url'.$adventure_trekking_camp_i,array( 'default' => '', 'sanitize_callback' => 'esc_url_raw' )); $wp_customize->add_control('adventure_trekking_camp_slider_button_url'.$adventure_trekking_camp_i,array( 'label' => esc_html__('Slider Button Url ','adventure-trekking-camp').$adventure_trekking_camp_i, 'section' => 'adventure_trekking_camp_slider_section', 'type' => 'url', 'active_callback' => 'adventure_trekking_camp_slider_dropdown', )); } $wp_customize->add_setting('adventure_trekking_camp_search_heading',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_search_heading',array( 'label' => esc_html__('Search Form Text','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_slider_section', 'setting' => 'adventure_trekking_camp_search_heading', 'type' => 'text', 'active_callback' => 'adventure_trekking_camp_slider_dropdown', )); // Project Section $wp_customize->add_section( 'adventure_trekking_camp_our_activities_section' , array( 'title' => __( 'Explore Activities Section Settings', 'adventure-trekking-camp' ), 'priority' => 4, ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_activities_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_activities_heading', array( 'label' => esc_html__( 'Explore Activities Section Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_our_activities_section', 'settings' => 'adventure_trekking_camp_section_activities_heading', ) ) ); $wp_customize->add_setting( 'adventure_trekking_camp_services_enable', array( 'type' => 'option', 'capability' => 'edit_theme_options', 'theme_supports' => '', 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'adventure_trekking_camp_callback_sanitize_switch', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Switch( $wp_customize, 'adventure_trekking_camp_services_enable', array( 'settings' => 'adventure_trekking_camp_services_enable', 'section' => 'adventure_trekking_camp_our_activities_section', 'label' => __( 'Check To show Section', 'adventure-trekking-camp' ), 'choices' => array( '1' => __( 'On', 'adventure-trekking-camp' ), 'off' => __( 'Off', 'adventure-trekking-camp' ), ), 'active_callback' => '', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_activities_text',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_activities_text',array( 'label' => esc_html__('Add Short Heading','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_our_activities_section', 'type' => 'text', 'active_callback' => 'adventure_trekking_camp_service_dropdown', )); $wp_customize->add_setting('adventure_trekking_camp_activities_heading',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_activities_heading',array( 'label' => esc_html__('Add Heading','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_our_activities_section', 'type' => 'text', 'active_callback' => 'adventure_trekking_camp_service_dropdown', )); $categories = get_categories(); $cats = array(); $i = 0; $cat_post[]= 'select'; foreach($categories as $category){ if($i==0){ $default = $category->slug; $i++; } $cat_post[$category->slug] = $category->name; } $wp_customize->add_setting('adventure_trekking_camp_activities_setting',array( 'default' => 'select', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_select', )); $wp_customize->add_control('adventure_trekking_camp_activities_setting',array( 'type' => 'select', 'choices' => $cat_post, 'label' => esc_html__('Select Category to display projects','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_our_activities_section', 'active_callback' => 'adventure_trekking_camp_service_dropdown', )); //Footer $wp_customize->add_section( 'adventure_trekking_camp_footer_copyright', array( 'title' => esc_html__( 'Footer Text', 'adventure-trekking-camp' ), 'priority' => 6 ) ); $wp_customize->add_setting( 'adventure_trekking_camp_section_footer_heading', array( 'default' => '', 'transport' => 'refresh', 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( new Adventure_Trekking_Camp_Customizer_Customcontrol_Section_Heading( $wp_customize, 'adventure_trekking_camp_section_footer_heading', array( 'label' => esc_html__( 'Footer Settings', 'adventure-trekking-camp' ), 'section' => 'adventure_trekking_camp_footer_copyright', 'settings' => 'adventure_trekking_camp_section_footer_heading', ) ) ); $wp_customize->add_setting('adventure_trekking_camp_footer_text',array( 'default' => '', 'sanitize_callback' => 'sanitize_text_field' )); $wp_customize->add_control('adventure_trekking_camp_footer_text',array( 'label' => esc_html__('Copyright Text','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_footer_copyright', 'type' => 'text' )); $wp_customize->add_setting('adventure_trekking_camp_footer_widget',array( 'default' => '4', 'sanitize_callback' => 'adventure_trekking_camp_sanitize_select' )); $wp_customize->add_control('adventure_trekking_camp_footer_widget',array( 'label' => esc_html__('Footer Per Column','adventure-trekking-camp'), 'section' => 'adventure_trekking_camp_footer_copyright', 'setting' => 'adventure_trekking_camp_footer_widget', 'type' => 'radio', 'choices' => array( '1' => __('1 Column', 'adventure-trekking-camp'), '2' => __('2 Column', 'adventure-trekking-camp'), '3' => __('3 Column', 'adventure-trekking-camp'), '4' => __('4 Column', 'adventure-trekking-camp') ), )); $wp_customize->get_setting( 'blogname' )->transport = 'postMessage'; $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; $wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage'; $wp_customize->selective_refresh->add_partial( 'blogname', array( 'selector' => '.site-title a', 'render_callback' => 'adventure_trekking_camp_customize_partial_blogname', ) ); $wp_customize->selective_refresh->add_partial( 'blogdescription', array( 'selector' => '.site-description', 'render_callback' => 'adventure_trekking_camp_customize_partial_blogdescription', ) ); //front page $num_sections = apply_filters( 'adventure_trekking_camp_front_page_sections', 4 ); // Create a setting and control for each of the sections available in the theme. for ( $i = 1; $i < ( 1 + $num_sections ); $i++ ) { $wp_customize->add_setting( 'panel_' . $i, array( 'default' => false, 'sanitize_callback' => 'adventure_trekking_camp_sanitize_dropdown_pages', 'transport' => 'postMessage', ) ); $wp_customize->add_control( 'panel_' . $i, array( /* translators: %d is the front page section number */ 'label' => sprintf( __( 'Front Page Section %d Content', 'adventure-trekking-camp' ), $i ), 'description' => ( 1 !== $i ? '' : __( 'Select pages to feature in each area from the dropdowns. Add an image to a section by setting a featured image in the page editor. Empty sections will not be displayed.', 'adventure-trekking-camp' ) ), 'section' => 'theme_options', 'type' => 'dropdown-pages', 'allow_addition' => true, 'active_callback' => 'adventure_trekking_camp_is_static_front_page', ) ); $wp_customize->selective_refresh->add_partial( 'panel_' . $i, array( 'selector' => '#panel' . $i, 'render_callback' => 'adventure_trekking_camp_front_page_section', 'container_inclusive' => true, ) ); } } add_action( 'customize_register', 'adventure_trekking_camp_customize_register' ); function adventure_trekking_camp_customize_partial_blogname() { bloginfo( 'name' ); } function adventure_trekking_camp_customize_partial_blogdescription() { bloginfo( 'description' ); } function adventure_trekking_camp_is_static_front_page() { return ( is_front_page() && ! is_home() ); } function adventure_trekking_camp_is_view_with_layout_option() { return ( is_page() || ( is_archive() && ! is_active_sidebar( 'sidebar-1' ) ) ); } define('ADVENTURE_TREKKING_CAMP_PRO_LINK',__('https://www.ovationthemes.com/wordpress/trekking-wordpress-theme/','adventure-trekking-camp')); /* Pro control */ if (class_exists('WP_Customize_Control') && !class_exists('Adventure_Trekking_Camp_Pro_Control')): class Adventure_Trekking_Camp_Pro_Control extends WP_Customize_Control{ public function render_content(){?>