Change text from add to cart button in productpages

This topic has 6 replies, 3 voices, and was last updated 8 years, 1 months ago ago by Eva Kemp

  • Avatar: cosmedia
    cosmedia
    Participant
    October 13, 2016 at 16:48

    How can i change the text from the add to cart button on a product page.

    Thanks!

    5 Answers
    Avatar: Eva
    Eva Kemp
    Support staff
    October 13, 2016 at 19:21

    Hello,

    Please refer to Woocommerce documentation https://docs.woocommerce.com/document/change-add-to-cart-button-text/

    Regards,
    Eva Kemp.

    Avatar: cosmedia
    cosmedia
    Participant
    October 14, 2016 at 03:34
    add_filter( 'woocommerce_product_single_add_to_cart_text', 'woo_custom_cart_button_text' );    // 2.1 +
     
    function woo_custom_cart_button_text() {
     
            return __( 'My Button Text', 'woocommerce' );
     
    

    I have added the code but it only changes on the front page, not a single product page

    Avatar: Robert Hall
    Robert Hall
    Support staff
    October 14, 2016 at 07:15

    Hello,

    You’ve added incorrect code. Please check it now.

    Regards,
    Robert Hall

    Avatar: cosmedia
    cosmedia
    Participant
    October 14, 2016 at 15:12

    It works now, thanks!

    Avatar: Eva
    Eva Kemp
    Support staff
    October 14, 2016 at 15:16

    Hello,

    You’re welcome.

    Regards,
    Eva Kemp.

  • Viewing 6 results - 1 through 6 (of 6 total)

The issue related to '‘Change text from add to cart button in productpages’' has been successfully resolved, and the topic is now closed for further responses

8theme customization service
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.