Astra_Woocommerce::shop_no_of_products()
Update Shop page grid
Description
Return
(int)
Source
File: inc/compatibility/woocommerce/class-astra-woocommerce.php
public function shop_no_of_products() { $taxonomy_page_display = get_option( 'woocommerce_category_archive_display', false ); if ( is_product_taxonomy() && 'subcategories' === $taxonomy_page_display ) { if ( $this->astra_woo_is_subcategory() ) { $products = astra_get_option( 'shop-no-of-products' ); return $products; } $products = wp_count_posts( 'product' )->publish; } else { $products = astra_get_option( 'shop-no-of-products' ); } return $products; }
Expand full source code Collapse full source code View on Trac