• Resolved muhsin38

    (@muhsin38)


    Hi,

    Can someone help me please?

    The add-to-cart button is not big enough for the text. How can I make the size of the box bigger or the best full width?

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

Viewing 5 replies - 1 through 5 (of 5 total)
  • Nico

    (@nicolamustone)

    Automattic Happiness Engineer

    Hello there,
    You can use this custom CSS code:

    .single_add_to_cart_button.button.alt {
        display: block;
        width: 100%;
    }

    You can use add custom CSS in Appearance > Customize > Additional CSS, as explained here: https://codex.www.ads-software.com/CSS#Custom_CSS_in_WordPress

    It should look like this:

    Add to Cart size
    Link to image: https://d.pr/i/X0qIMj

    Thread Starter muhsin38

    (@muhsin38)

    Thanks for your answer, but still doesn’t work…

    Before I started with this I added this code to the functions.phh to place the button below the price and above the text:
    remove_action( ‘woocommerce_single_product_summary’,
    ‘woocommerce_template_single_add_to_cart’, 30 );
    add_action( ‘woocommerce_single_product_summary’,
    ‘woocommerce_template_single_add_to_cart’, 19 );

    Does this maybe have something to do with it not working? Because before I placed this code it was wide and was working.

    Hi there!

    The code should work correctly, please try adding it to your child-theme style.css file and clearing cache after the change.

    Let me know if that works!

    Thread Starter muhsin38

    (@muhsin38)

    Hi,

    Thank you very much. It works ??

    Greetings,

    Mussi

    Plugin Support Gabriel – a11n

    (@gabrielfuentes)

    We are happy to help ??

    Great! I’m going to mark this as resolved – if you have any further questions, you can start a new thread.

    Cheers!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Add to cart buttton size’ is closed to new replies.