| Server IP : 213.186.33.4 / Your IP : 216.73.216.222 Web Server : Apache System : Linux webm005.cluster103.gra.hosting.ovh.net 6.18.39-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Tue Jul 21 12:03:15 CEST 2026 x86_64 User : karinebmkh ( 644538) PHP Version : 8.4.22 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/karinebmkh/www2/wp-content/themes/glaza/theme_options/ |
Upload File : |
<?php
if ( ! function_exists( 'glaza_theme_options_wc' ) ) {
function glaza_theme_options_wc() {
return array(
'id' => 'glaza_config_section_wc',
'title' => esc_html__( 'Woocommerce', 'glaza' ),
'desc' => esc_html__( 'Select options for your shop on the website.', 'glaza' ),
'icon' => 'el el-shopping-cart'
);
}
}
/**
* @return array
* shop the post layout
*/
if ( ! function_exists( 'glaza_theme_options_wc_stp' ) ) {
function glaza_theme_options_wc_stp() {
return array(
'id' => 'glaza_config_section_wc_stp',
'title' => esc_html__( 'Shop the Post', 'glaza' ),
'desc' => esc_html__( 'Select layout for shop the post section.', 'glaza' ),
'icon' => 'el el-shopping-cart',
'subsection' => true,
'fields' => array(
array(
'id' => 'section_start_wc_stp',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Post Listing - STP Options', 'glaza' ),
'subtitle' => esc_html__( 'These options below only apply to list on the blog, archive and category pages. For the page built with page builder, you can config in the widget settings.', 'glaza' ),
'indent' => true
),
array(
'id' => 'classic_products_per_row',
'title' => esc_html__( 'Classic - Product Columns', 'glaza' ),
'subtitle' => esc_html__( 'select a number of product columns for the classic layout.', 'glaza' ),
'type' => 'select',
'options' => array(
'4' => esc_html__( '4 columns', 'glaza' ),
'5' => esc_html__( '5 columns', 'glaza' )
),
'default' => '4'
),
array(
'id' => 'list_products_per_row',
'title' => esc_html__( 'List - Product Columns', 'glaza' ),
'subtitle' => esc_html__( 'select a number of product columns for the list layout.', 'glaza' ),
'type' => 'select',
'options' => array(
'4' => esc_html__( '4 columns', 'glaza' ),
'5' => esc_html__( '5 columns', 'glaza' )
),
'default' => '5'
),
array(
'id' => 'section_end_wc_stp',
'type' => 'section',
'class' => 'ruby-section-end no-border',
'indent' => false
),
array(
'id' => 'section_start_wc_single_stp',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Single Post - STP Options', 'glaza' ),
'subtitle' => esc_html__( 'These options below will apply to the single post page.', 'glaza' ),
'indent' => true
),
array(
'id' => 'single_post_shop_title',
'type' => 'text',
'title' => esc_html__( 'Section Title', 'glaza' ),
'subtitle' => esc_html__( 'Input the title for shop the post section, Leave blank if you want to remove it.', 'glaza' ),
'switch' => true,
'default' => esc_html__( 'Shop The Post', 'glaza' )
),
array(
'id' => 'single_post_shop_layout',
'type' => 'select',
'title' => esc_html__( 'Shop The Post Layout', 'glaza' ),
'subtitle' => esc_html__( 'select a layout for the product listings in the single post page', 'glaza' ),
'options' => array(
'4' => esc_html__( 'Grid 4 columns', 'glaza' ),
'5' => esc_html__( 'Grid 5 columns', 'glaza' ),
'carousel' => esc_html__( 'Carousel Slider', 'glaza' )
),
'default' => '4'
),
array(
'id' => 'single_post_shop_style',
'type' => 'select',
'title' => esc_html__( 'Shop The Post Style', 'glaza' ),
'subtitle' => esc_html__( 'select a style for the product listings in the single post page', 'glaza' ),
'options' => array(
'light' => esc_html__( 'Light', 'glaza' ),
'dark' => esc_html__( 'Dark', 'glaza' )
),
'default' => 'light'
),
array(
'id' => 'single_post_shop_position',
'type' => 'select',
'title' => esc_html__( 'Section Position', 'glaza' ),
'subtitle' => esc_html__( 'select a position to show your product lists in the single post page.', 'glaza' ),
'options' => array(
'top' => esc_html__( 'Top of Single Content', 'glaza' ),
'bottom' => esc_html__( 'Bottom of Single Content', 'glaza' )
),
'default' => 'top',
),
array(
'id' => 'section_end_wc_single_stp',
'type' => 'section',
'class' => 'ruby-section-end no-border',
'indent' => false
),
)
);
}
}
/**
* @return array
* styling
*/
if ( ! function_exists( 'glaza_theme_options_wc_styling' ) ) {
function glaza_theme_options_wc_styling() {
return array(
'id' => 'glaza_config_section_wc_styling',
'title' => esc_html__( 'Elements Styling', 'glaza' ),
'desc' => esc_html__( 'Select styling options of your shop.', 'glaza' ),
'icon' => 'el el-adjust-alt',
'subsection' => true,
'fields' => array(
array(
'id' => 'section_start_wc_styling',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Meta Options', 'glaza' ),
'indent' => true
),
array(
'id' => 'wc_sale_percent',
'type' => 'switch',
'title' => esc_html__( 'Show Percentage Saved', 'glaza' ),
'subtitle' => esc_html__( 'display Percentage saved on WooCommerce sale products', 'glaza' ),
'switch' => true,
'default' => 1
),
array(
'id' => 'wc_wishlist',
'type' => 'switch',
'title' => esc_html__( 'Wishlist Icon', 'glaza' ),
'subtitle' => esc_html__( 'enable or disable the Wishlist icon in the product listing.', 'glaza' ),
'desc' => esc_html__( 'This option requests the Wishlist plugin to work.', 'glaza' ),
'switch' => true,
'default' => 1
),
array(
'id' => 'wc_price_color',
'title' => esc_html__( 'Price Color', 'glaza' ),
'subtitle' => esc_html__( 'select a color value for the pricing, this option will override on default theme color, Leave blank if you want to set default (#111111).', 'glaza' ),
'type' => 'color',
'transparent' => false,
'validate' => 'color'
),
array(
'id' => 'wc_sale_color',
'title' => esc_html__( 'Sale Icon Background', 'glaza' ),
'subtitle' => esc_html__( 'select a background color value for the sale icon, this option will override on default theme color, Leave blank if you want to set default (#be3fff).', 'glaza' ),
'type' => 'color',
'transparent' => false,
'validate' => 'color',
),
array(
'id' => 'section_end_wc_styling',
'type' => 'section',
'class' => 'ruby-section-end',
'indent' => false
),
array(
'id' => 'section_start_wc_typo',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Typography Options', 'glaza' ),
'indent' => true
),
array(
'id' => 'font_product_title',
'type' => 'typography',
'title' => esc_html__( 'Product Title Font', 'glaza' ),
'subtitle' => esc_html__( 'select font values for product title in the listing.', 'glaza' ),
'desc' => esc_html__( 'Default [ font-size: 16px | font-weight: 400 ]', 'glaza' ),
'google' => true,
'font-backup' => true,
'text-align' => false,
'color' => true,
'text-transform' => true,
'letter-spacing' => true,
'line-height' => false,
'units' => 'px',
'default' => array(
'font-family' => 'Montserrat',
'font-size' => '16px',
'font-weight' => '400',
'text-transform' => 'none',
),
'output' => array(
'.woocommerce-loop-product__title',
'.product-name a',
'.widget_products.woocommerce ul.product_list_widget li > a'
)
),
array(
'id' => 'font_product_single',
'type' => 'text',
'class' => 'small-text',
'validate' => 'numeric',
'title' => esc_html__( 'Single Title Font Size', 'glaza' ),
'subtitle' => esc_html__( 'select a font size value for the product title of single product page.', 'glaza' ),
'desc' => esc_html__( 'Default [ font-size: 24px]', 'glaza' ),
),
array(
'id' => 'font_product_stp',
'type' => 'text',
'class' => 'small-text',
'validate' => 'numeric',
'title' => esc_html__( 'ShopThePost Title Font Size', 'glaza' ),
'subtitle' => esc_html__( 'select a font size value for product title in shop the post section.', 'glaza' ),
'desc' => esc_html__( 'Default [ font-size: 13px]', 'glaza' ),
),
array(
'id' => 'font_price',
'type' => 'typography',
'title' => esc_html__( 'Product Price Font', 'glaza' ),
'subtitle' => esc_html__( 'select font values for price elements.', 'glaza' ),
'desc' => esc_html__( 'Default [ font-family: Montserrat | font-size: 16px | font-weight: 500 ]', 'glaza' ),
'google' => true,
'font-backup' => true,
'text-align' => false,
'color' => false,
'text-transform' => true,
'letter-spacing' => true,
'line-height' => false,
'units' => 'px',
'default' => array(
'font-size' => '16px',
'font-family' => 'Montserrat',
'font-weight' => '500',
'text-transform' => 'uppercase',
),
'output' => array(
'.woocommerce .price',
'.woocommerce div.product .product-loop-content .price',
'.woocommerce span.onsale',
'.woocommerce span.onsale.percent',
'.woocommerce-Price-amount.amount',
'.woocommerce .quantity .qty'
)
),
array(
'id' => 'font_single_price',
'type' => 'text',
'class' => 'small-text',
'validate' => 'numeric',
'title' => esc_html__( 'Single Price Font Size', 'glaza' ),
'subtitle' => esc_html__( 'select a price font size value for single product pages.', 'glaza' ),
'desc' => esc_html__( 'Default [ font-size: 34]', 'glaza' ),
),
array(
'id' => 'font_stp_price',
'type' => 'text',
'class' => 'small-text',
'validate' => 'numeric',
'title' => esc_html__( 'ShopThePost Price Font Size', 'glaza' ),
'subtitle' => esc_html__( 'select a font size value for price in shop the post section.', 'glaza' ),
'desc' => esc_html__( 'Default [ font-size: 13px]', 'glaza' ),
),
array(
'id' => 'section_end_wc_typo',
'type' => 'section',
'class' => 'ruby-section-end no-border',
'indent' => false
),
)
);
}
}
/**
* @return array
* single product
*/
if ( ! function_exists( 'glaza_theme_options_wc_page' ) ) {
function glaza_theme_options_wc_page() {
return array(
'id' => 'glaza_config_section_wc_page',
'title' => esc_html__( 'Woocommerce Pages', 'glaza' ),
'desc' => esc_html__( 'Select options for the shop and archive and single product pages.', 'glaza' ),
'icon' => 'el el-folder-open',
'subsection' => true,
'fields' => array(
array(
'id' => 'section_start_wc_shop',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Shop Page Options', 'glaza' ),
'indent' => true
),
array(
'id' => 'wc_shop_posts_per_page',
'type' => 'text',
'class' => 'small-text',
'validate' => 'numeric',
'title' => esc_html__( 'Number of products', 'glaza' ),
'subtitle' => esc_html__( 'select number of products per page, leave blank if you want to set as default.', 'glaza' ),
'switch' => true,
'default' => ''
),
array(
'id' => 'wc_shop_sidebar_name',
'type' => 'select',
'title' => esc_html__( 'Shop Sidebar Name', 'glaza' ),
'subtitle' => esc_html__( 'select a sidebar for the shop page.', 'glaza' ),
'options' => glaza_config_sidebar_name(),
'default' => 'glaza_sidebar_default',
),
array(
'id' => 'wc_shop_sidebar_position',
'type' => 'image_select',
'title' => esc_html__( 'Shop Sidebar Position', 'glaza' ),
'subtitle' => esc_html__( 'Select sidebar position for the shop page.', 'glaza' ),
'options' => glaza_config_sidebar_position( false ),
'default' => 'none'
),
array(
'id' => 'section_end_wc_shop',
'type' => 'section',
'class' => 'ruby-section-end',
'indent' => false
),
array(
'id' => 'section_start_wc_archive',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Archive Page Options', 'glaza' ),
'indent' => true
),
array(
'id' => 'wc_archive_sidebar_name',
'type' => 'select',
'title' => esc_html__( 'Sidebar Name', 'glaza' ),
'subtitle' => esc_html__( 'select a sidebar for product category and archive pages.', 'glaza' ),
'options' => glaza_config_sidebar_name(),
'default' => 'glaza_sidebar_default',
),
array(
'id' => 'wc_archive_sidebar_position',
'type' => 'image_select',
'title' => esc_html__( 'Sidebar Position', 'glaza' ),
'subtitle' => esc_html__( 'Select a sidebar position for product category and archive pages.', 'glaza' ),
'options' => glaza_config_sidebar_position( false ),
'default' => 'none'
),
array(
'id' => 'section_end_wc_archive',
'type' => 'section',
'class' => 'ruby-section-end',
'indent' => false
),
array(
'id' => 'section_start_wc_single',
'type' => 'section',
'class' => 'ruby-section-start',
'title' => esc_html__( 'Single Product Page', 'glaza' ),
'indent' => true
),
array(
'id' => 'wc_box_review',
'type' => 'switch',
'title' => esc_html__( 'Show Review Box', 'glaza' ),
'subtitle' => esc_html__( 'enable or disable the review box in the single product page.', 'glaza' ),
'switch' => true,
'default' => 1
),
array(
'id' => 'wc_related_posts_per_page',
'type' => 'text',
'class' => 'small-text',
'validate' => 'numeric',
'title' => esc_html__( 'Related Products', 'glaza' ),
'subtitle' => esc_html__( 'select number of products per page, leave blank if you want to set as default.', 'glaza' ),
'switch' => true,
'default' => '4'
),
array(
'id' => 'section_end_wc_single',
'type' => 'section',
'class' => 'ruby-section-end no-border',
'indent' => false
),
)
);
}
}