Hi. How can we help?

How to Move request a quote button in the loop or in single page

To move request a quote button - add this code in the file functions.php of your theme

 

/* To move request a quote button in the loop */
if ( class_exists( 'YITH_Request_Quote_Premium' ) ) {
remove_action( 'woocommerce_after_shop_loop_item', array( YITH_Request_Quote_Premium(), 'add_button_shop' ), 15 );
add_action( 'your_loop_hook', array( YITH_Request_Quote_Premium(), 'add_button_shop' ) );
}

/* To move request a quote button in the single page */
if ( class_exists( 'YITH_YWRAQ_Frontend' ) && ! function_exists( 'ywraq_move_button_quote_single_product_page' ) ) {
add_action( 'woocommerce_before_single_product', 'ywraq_move_button_quote_single_product_page' );
function ywraq_move_button_quote_single_product_page() {
remove_action( 'woocommerce_single_product_summary', array( YITH_YWRAQ_Frontend(), 'add_button_single_page' ), 35 );
add_action( 'your_hook', array( YITH_YWRAQ_Frontend(), 'add_button_single_page' ) );
}
}
Was this article helpful?
3 out of 34 found this helpful

Back to Help Center >