add_section( 'acommerce_archive_settings', array( 'title' => esc_html__( 'Archive & Blog Page', 'acommerce' ), 'priority' => 3, 'panel' =>'general_setting' ) ); //excerpt word limit $wp_customize->add_setting( 'acommerce_the_excerpt_word_limit', array( 'default' => 15, 'sanitize_callback' => 'absint', ) ); $wp_customize->add_control( 'acommerce_the_excerpt_word_limit', array( 'section' => 'acommerce_archive_settings', 'label' => esc_html__( 'Limit Excerpt', 'acommerce' ), 'description' => esc_html__( 'Number of excerpt limit word.', 'acommerce' ), 'type' => 'number', ) ); //Archive or blog page section $wp_customize->add_setting( 'acommerce_archive_blog_layout', array( 'default' =>'list', 'sanitize_callback' => 'acommerce_sanitize_radio' ) ); $wp_customize->add_control( new aCommerce_Radio_Control( $wp_customize, 'acommerce_archive_blog_layout', array( 'type' => 'radio', 'label' => esc_html__( 'Blog Layout', 'acommerce' ), 'section' => 'acommerce_archive_settings', 'choices' => array( 'list' => esc_url( ACOMMERCE_THEME_IMG . 'blog/blog-list.png'), 'blog' => esc_url( ACOMMERCE_THEME_IMG . 'blog/blog-grid.png'), 'macn' => esc_url( ACOMMERCE_THEME_IMG . 'blog/blog-masonry.png'), ) ) ) ); //Related title $wp_customize->add_setting( 'acommerce_related_post_title', array( 'default' => esc_html__('RELATED ARTICLES','acommerce'), 'sanitize_callback' => 'sanitize_text_field', ) ); $wp_customize->add_control( 'acommerce_related_post_title', array( 'section' => 'acommerce_archive_settings', 'label' => esc_html__( 'Related Post Title', 'acommerce' ), 'description' => esc_html__( 'Your Related Articles Title.', 'acommerce' ), 'type' => 'text', ) ); //excerpt word limit $wp_customize->add_setting( 'acommerce_related_post_count', array( 'default' => 3, 'sanitize_callback' => 'absint', ) ); $wp_customize->add_control( 'acommerce_related_post_count', array( 'section' => 'acommerce_archive_settings', 'label' => esc_html__( 'Number of Related Post', 'acommerce' ), 'description' => esc_html__( 'Number of related Post Count.', 'acommerce' ), 'type' => 'number', ) ); } add_action( 'customize_register', 'acommerce_customize_archive_page_settings_new' );