How to change position of ‘Add to Wishlist’ button in WooCommerce Wishlists

nine kopfer 295988 unsplash

If you’re using WooCommerce Wishlists, you might want to change the position of the ‘Add to Wishlist’ button in the single product template.

To do this, you just use theĀ woocommerce_wishlists_template_location filter:

function prefix_wishlist_template_location( $template_hook, $product_id ) {
// Return your hook here
return 'woocommerce_single_product_summary';
add_filter( 'woocommerce_wishlists_template_location', 'prefix_wishlist_template_location', 10, 2 );

Just substitute whichever hook you want to call the button on.

Leave a Reply

Your email address will not be published. All fields are required.