Last active
November 22, 2017 18:58
-
-
Save WPprodigy/08844633bceaab3ee26db814939eab0c to your computer and use it in GitHub Desktop.
Edit the amount and columns of up-sells on the single product page in WooCommerce
This file contains hidden or 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
add_filter( 'woocommerce_upsells_total', 'wc_ninja_edit_upsells_total', 10 ); | |
function wc_ninja_edit_upsells_total( $limit ) { | |
return 8; | |
} | |
add_filter( 'woocommerce_upsells_columns', 'wc_ninja_edit_upsells_columns', 10 ); | |
function wc_ninja_edit_upsells_columns( $columns ) { | |
return 4; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment