Web Hosting
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WooCommerce buy now button customization

Discussion in 'Troubleshooting & How-To's' started by naveen, Oct 5, 2017.

  1. naveen

    New Member

    Joined:
    Oct 5, 2017
    Messages:
    1
    Likes Received:
    0
    I am using the woocommerce plugin and I would like to lock the buy now button with social share locker so that when a user wants to click the button on my site he should share on social networks. I have added new javascript code and created the new button but am unable to add social locker shortcode to that code

    code:

    add_filter( 'add_to_cart_text', 'woo_custom_single_add_to_cart_text' );
    add_filter( 'woocommerce_product_single_add_to_cart_text', 'woo_custom_single_add_to_cart_text' ); // 2.1 +

    function woo_custom_single_add_to_cart_text() {

    return __( 'buy now', 'woocommerce' );

    }
     
    #1

Share This Page

Web Hosting