Quantcast
Channel: WordPress.org Forums » [WooCommerce] Support
Viewing all articles
Browse latest Browse all 102129

brown7905 on "[Plugin: WooCommerce - excelling eCommerce] Changing number of products displayed on page"

$
0
0

I am working with someone to create a store on their site using WooCommerce.

I have tried literally everything to change the number of products that appear on the front page and no matter what I do it will not change.

The code I've been trying on functions.php (among many others) is

// Display 24 products per page. Goes in functions.php
add_filter( 'loop_shop_per_page', create_function( '$cols', 'return 24;' ), 20 );

It hasn't worked. I've also tried to change the number of posts under Settings>Reading. No luck there.

I was able to change to the number of columns by using this code

// Change number or products per row to 3
add_filter('loop_shop_columns', 'loop_columns');
if (!function_exists('loop_columns')) {
	function loop_columns() {
		return 3; // 3 products per row
	}
}

For some reason this worked in functions.php, so I have no idea why the number of products changing isn't working here.

The site is http://www.melissatucker.com/shop

If anyone has any ideas I'd really appreciate it!

http://wordpress.org/extend/plugins/woocommerce/


Viewing all articles
Browse latest Browse all 102129

Trending Articles