• Resolved grant512

    (@grant512)


    Hello, is there a way to change Add to cart functionality to Enquire price where form can just pop-up?

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author WPXtension

    (@wpxteam)

    Hi,

    I hope you are doing well today. Which plugin you are using to get the pop-up? Do they have any shortcode to display the Ask for Price button and functionality?

    Please contact the plugin/theme author regarding a shortcode of the Ask for Price button. If they have a shortcode and variation ID that can be passed, you can replace the Add to Cart button with Ask for Price.

    Best Regards

    Thread Starter grant512

    (@grant512)

    Hi team, my goal is not to use e-commerce functionality for now until it integrate in our system. Instead of add to cart I would like for customers to enquire instead.

    Plugin Author WPXtension

    (@wpxteam)

    Hi,

    I have successfully understood your goal. Unfortunately, the enquire form is not currently available in our plugin.

    Are you using any plugin to achieve this: https://prnt.sc/R5GA_UxqaNue?

    If so, do they provide any shortcodes? If they have a shortcode of the popup form, you can replace the add-to-cart button with that shortcode.

    Here is a sample snippet, you can try it on your site. Then customize it as per your need:

    add_filter( 'pvtfw_row_cart_btn_is', function( $default, $product_id, $cart_url, $product_url, $variant_id, $text ){
       return "Do what you want here!";
    }, 10, 6);

    Shortcode example:

    add_filter( 'pvtfw_row_cart_btn_is', function( $default, $product_id, $cart_url, $product_url, $variant_id, $text ){
       return do_shortcode('[A_SHORTCODE]');
    }, 10, 6);

    I hope this will help.

    Best Regards

    Thread Starter grant512

    (@grant512)

    Hi, yes I am using popup shortcode [elementor-template id=”3003″]. Should I just add it following your codes above?

    add_filter( ‘pvtfw_row_cart_btn_is’, function( $default, $product_id, $cart_url, $product_url, $variant_id, $text ){ return “Do what you want here!”; }, 10, 6);

    add_filter( ‘pvtfw_row_cart_btn_is’, function( $default, $product_id, $cart_url, $product_url, $variant_id, $text ){ return do_shortcode(‘[elementor-template id=”3003″]‘); }, 10, 6);

    Plugin Author WPXtension

    (@wpxteam)

    Hi,

    You are using a shortcode so you can use the second snippet. You do not need to use the first snippet. Just add the following:

    add_filter( 'pvtfw_row_cart_btn_is', function( $default, $product_id, $cart_url, $product_url, $variant_id, $text ){ 
       return do_shortcode('[elementor-template id="3003"]') 
    }, 10, 6);
    • This reply was modified 10 months, 3 weeks ago by WPXtension.
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Change Add to Cart to Enquire Price’ is closed to new replies.