Created
September 16, 2019 09:51
-
-
Save daviddunnington/f0c4a246b21f455038d456696f03b3e8 to your computer and use it in GitHub Desktop.
Modify Woocommerce upsell sort order
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
function wc_custom_upsell_sorting() { | |
woocommerce_upsell_display( - 1, 4, 'menu_order', 'ASC' ); | |
} | |
remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_upsell_display', 15 ); | |
add_action( 'woocommerce_after_single_product_summary', 'wc_custom_upsell_sorting', 15 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment