• I am trying to display a custom list of products. I created this shortcode. But I am trying to hide the pagination.

    function my_wpsc_sale_shortcode($atts) {
    
    	$number_per_page = 2;
    	$query = shortcode_atts(array(
    		'category_id' => isset($atts['cat']) ? $atts['cat'] : 0,
    		'limit_of_items' => 3,
    		'sort_order' => rand,
    		'price' => '',
    		'number_per_page' => $number_per_page,
    		'page' => 0,
    		'nopaging' => 0,
    		'use_pagination' => 0,
    		'paged' => 0,
    
    	), $atts);
    
    	return wpsc_display_products_page($query);
    
    }
    add_shortcode('my_wpsc_onsale', 'my_wpsc_sale_shortcode');

    https://www.ads-software.com/plugins/wp-e-commerce/

Viewing 1 replies (of 1 total)
  • Thread Starter Bloke

    (@bloke)

    I was able to put ‘tag’ => ‘tag name here’,
    and it displayed just the products with that tag but is there a way to accomplish like above without using tags?

Viewing 1 replies (of 1 total)
  • The topic ‘Hiding pagination in shortcode’ is closed to new replies.