golden hour
/home/godaofbq/dev.hyperredbed.com/wp-content/plugins/shopengine/widgets
⬆️ Go Up
Upload
File/Folder
Size
Actions
add-to-cart
-
Del
OK
additional-information
-
Del
OK
advanced-search
-
Del
OK
archive-description
-
Del
OK
archive-products
-
Del
OK
archive-result-count
-
Del
OK
archive-title
-
Del
OK
archive-view-mode
-
Del
OK
breadcrumbs
-
Del
OK
cart-table
-
Del
OK
cart-totals
-
Del
OK
checkout-coupon-form
-
Del
OK
checkout-form-additional
-
Del
OK
checkout-form-billing
-
Del
OK
checkout-form-login
-
Del
OK
checkout-form-shipping
-
Del
OK
checkout-payment
-
Del
OK
checkout-review-order
-
Del
OK
checkout-shipping-methods
-
Del
OK
cross-sells
-
Del
OK
deal-products
-
Del
OK
empty-cart-message
-
Del
OK
filter-orderby
-
Del
OK
filter-products-per-page
-
Del
OK
filterable-product-list
-
Del
OK
init
-
Del
OK
lazy-cache.php
2.7 KB
Del
OK
manifest.php
3.08 KB
Del
OK
notice
-
Del
OK
prod-short-code.php
1.6 KB
Del
OK
product-categories
-
Del
OK
product-category-lists
-
Del
OK
product-description
-
Del
OK
product-excerpt
-
Del
OK
product-image
-
Del
OK
product-list
-
Del
OK
product-meta
-
Del
OK
product-price
-
Del
OK
product-rating
-
Del
OK
product-review
-
Del
OK
product-share
-
Del
OK
product-sku
-
Del
OK
product-stock
-
Del
OK
product-tabs
-
Del
OK
product-tags
-
Del
OK
product-title
-
Del
OK
products.php
6.42 KB
Del
OK
recently-viewed-products
-
Del
OK
related
-
Del
OK
return-to-shop
-
Del
OK
shop.php
9.14 KB
Del
OK
up-sells
-
Del
OK
view-single-product
-
Del
OK
widget-helper.php
7.99 KB
Del
OK
Edit: prod-short-code.php
<?php namespace ShopEngine\Widgets; defined('ABSPATH') || exit; class Prod_Short_Code extends \WC_Shortcode_Products { public function __construct($settings = array(), $type = 'products') { $this->settings = $settings; $this->type = $type; $this->attributes = $this->parse_attributes([ 'columns' => $settings['shopengine_columns'], 'rows' => $settings['shopengine_rows'], 'paginate' => $settings['shopengine_paginate'], 'cache' => false, ]); $this->query_args = $this->parse_query_args(); } protected function parse_query_args() { $query_args = [ 'post_type' => 'product', 'post_status' => 'publish', 'ignore_sticky_posts' => true, 'no_found_rows' => false === wc_string_to_bool($this->attributes['paginate']), ]; $settings = $this->settings; if($settings['shopengine_paginate'] === 'yes') { //phpcs:ignore WordPress.Security.NonceVerification.Recommended -- It's a fronted user part, not possible to verify nonce here $page = empty( $_GET['product-page'] ) ? 1 : absint($_GET['product-page']); if ($page > 1) { $query_args['paged'] = $page; } $ord_arg = WC()->query->get_catalog_ordering_args(); $query_args['orderby'] = $ord_arg['orderby']; $query_args['order'] = $ord_arg['order']; } $query_args['fields'] = 'ids'; $query_args['post_type'] = 'product'; $query_args['posts_per_page'] = intval($settings['shopengine_columns'] * $settings['shopengine_rows']); return $query_args; } protected function get_query_results() { $results = parent::get_query_results(); return $results; } }
Save