Created
April 9, 2013 19:53
-
-
Save growdev/5348814 to your computer and use it in GitHub Desktop.
WooCommerce - Change Number of Related Products displayed on the Product page
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Add this to your theme's functions.php file | |
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20 ); | |
function custom_output_related_products() { | |
// Display 5 products in 5 columns | |
woocommerce_related_products( 5, 5 ); | |
} | |
add_action( 'woocommerce_after_single_product_summary', 'custom_output_related_products', 20 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment