Current path: home/webdevt/www/wdp/wp-content/themes/quadric/framework/modules/woocommerce/options-map/
?? Go up: /home/webdevt/www/wdp/wp-content/themes/quadric/framework/modules/woocommerce
<?php
if ( ! function_exists('edgtf_quadric_woocommerce_options_map') ) {
/**
* Add Woocommerce options page
*/
function edgtf_quadric_woocommerce_options_map() {
edgtf_quadric_add_admin_page(
array(
'slug' => '_woocommerce_page',
'title' => esc_html__( 'Woocommerce', 'quadric' ),
'icon' => 'fa fa-header'
)
);
/**
* Product List Settings
*/
$panel_product_list = edgtf_quadric_add_admin_panel(
array(
'page' => '_woocommerce_page',
'name' => 'panel_product_list',
'title' => esc_html__( 'Product List', 'quadric' )
)
);
edgtf_quadric_add_admin_field(array(
'name' => 'edgtf_woo_products_list_full_width',
'type' => 'yesno',
'label' => esc_html__( 'Enable Full Width Template', 'quadric' ),
'default_value' => 'no',
'description' => esc_html__( 'Enabling this option will enable full width template for shop page', 'quadric' ),
'parent' => $panel_product_list,
));
edgtf_quadric_add_admin_field(array(
'name' => 'edgtf_woo_product_list_columns',
'type' => 'select',
'label' => esc_html__( 'Product List Columns', 'quadric' ),
'default_value' => 'edgtf-woocommerce-columns-4',
'description' => esc_html__( 'Choose number of columns for product listing and related products on single product', 'quadric' ),
'options' => array(
'edgtf-woocommerce-columns-3' => esc_html__( '3 Columns (2 with sidebar)', 'quadric' ),
'edgtf-woocommerce-columns-4' => esc_html__( '4 Columns (3 with sidebar)', 'quadric' )
),
'parent' => $panel_product_list,
));
edgtf_quadric_add_admin_field(array(
'name' => 'edgtf_woo_products_per_page',
'type' => 'text',
'label' => esc_html__( 'Number of products per page', 'quadric' ),
'default_value' => '',
'description' => esc_html__( 'Set number of products on shop page', 'quadric' ),
'parent' => $panel_product_list,
'args' => array(
'col_width' => 3
)
));
edgtf_quadric_add_admin_field(array(
'name' => 'edgtf_products_list_title_tag',
'type' => 'select',
'label' => esc_html__( 'Products Title Tag', 'quadric' ),
'default_value' => 'h1',
'description' => '',
'options' => array(
'h1' => 'h1',
'h2' => 'h2',
'h3' => 'h3',
'h4' => 'h4',
'h5' => 'h5',
'h6' => 'h6',
),
'parent' => $panel_product_list,
));
/**
* Single Product Settings
*/
$panel_single_product = edgtf_quadric_add_admin_panel(
array(
'page' => '_woocommerce_page',
'name' => 'panel_single_product',
'title' => esc_html__( 'Single Product', 'quadric' )
)
);
edgtf_quadric_add_admin_field(array(
'name' => 'edgtf_single_product_title_tag',
'type' => 'select',
'label' => esc_html__( 'Single Product Title Tag', 'quadric' ),
'default_value' => 'h1',
'description' => '',
'options' => array(
'h1' => 'h1',
'h2' => 'h2',
'h3' => 'h3',
'h4' => 'h4',
'h5' => 'h5',
'h6' => 'h6',
),
'parent' => $panel_single_product,
));
}
add_action( 'edgtf_quadric_options_map', 'edgtf_quadric_woocommerce_options_map',20 );
}