How can I change from 2 columns of products per page to 3 or 4 columns.
I have tried adding the following to the end of functions.php -
// Override theme default specification for product # per row
function loop_columns() {
return 5; // 5 products per row
}
add_filter('loop_shop_columns', 'loop_columns', 999);
The problem I have is that this only works if its outside on the "?>" which closes the php. But then it also displays the override code at the top of the page.