Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

Lay Theme Forum

  1. Home
  2. Bug Reports
  3. top/bottom padding woocommerce not working

top/bottom padding woocommerce not working

Scheduled Pinned Locked Moved Bug Reports
8 Posts 2 Posters 728 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R
    R
    ricorico4321
    wrote on last edited by
    #1

    Hi,
    I've been trying to adjust top/bottom padding for add to cart button for WooCommerce, but changes won't apply.
    Thanks

    1 Reply Last reply
    0
    • arminunruhA
      arminunruhA
      arminunruh
      Global Moderator
      wrote on last edited by
      #2

      link please ?
      Screenshot 2025-02-19 at 13.37.57.png

      for me it works

      1 Reply Last reply
      0
      • R
        R
        ricorico4321
        wrote on last edited by
        #3

        my bad!

        Capture d’écran 2025-02-19 à 14.35.53.png
        Capture d’écran 2025-02-19 à 14.36.02.png

        1 Reply Last reply
        0
        • arminunruhA
          arminunruhA
          arminunruh
          Global Moderator
          wrote on last edited by
          #4

          ah i understand now, i thought you meant a different setting

          so this setting does not affect "the add to cart button"

          but it does affect the buttons in checkout and cart: yourwebsite.com/cart/

          Screenshot 2025-02-19 at 14.54.08.png

          the reason for why the add to cart button has a fixed height thats not changeable is, because historically we only had these big inputs you can see below and i wanted the button to always have the same height as these inputs:

          Screenshot 2025-02-19 at 14.55.01.png

          do you want to change the button paddings for the element:
          +woocommerce → +add to cart button?

          if so use this css below.

          change height and line-height for changing the height.
          make sure line-height is 2px smaller than height.

          for changing space left and right, change padding-left and padding-right values.

          a.button.add_to_cart_button{
              height: 52px!important;
              line-height: 50px!!important
              padding-top: 0 !important;
              padding-bottom: 0 !important;
              padding-left: 10px!important;
              padding-right: 10px!important;
          }
          

          Enter this css in "lay options" -> "custom css & html" -> "custom css for desktop"
          or "css for mobile"

          1 Reply Last reply
          0
          • arminunruhA
            arminunruhA
            arminunruh
            Global Moderator
            wrote on last edited by
            #5

            for changing the add to cart button on the single product page use:

            .single-product .single_add_to_cart_button{
                height: 52px!important;
                line-height: 50px!!important
                padding-top: 0 !important;
                padding-bottom: 0 !important;
                padding-left: 10px!important;
                padding-right: 10px!important;
            }
            
            1 Reply Last reply
            0
            • arminunruhA
              arminunruhA
              arminunruh
              Global Moderator
              wrote on last edited by
              #6

              ok after reviewing this it seems that the padding top / bottom only applies to like 2 buttons

              so i will remove this setting

              i will introduce a new setting for the button height

              but the setting "padding left/right" seems to apply to every button

              1 Reply Last reply
              0
              • arminunruhA
                arminunruhA
                arminunruh
                Global Moderator
                wrote on last edited by arminunruh
                #7

                if u update lay theme now u will have this setting:
                Add to Cart Button Height (px)

                Screenshot 2025-02-19 at 16.41.01.png

                so you dont need to use the custom css i wrote

                1 Reply Last reply
                0
                • R
                  R
                  ricorico4321
                  wrote on last edited by
                  #8

                  thank you!

                  1 Reply Last reply
                  0

                  Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                  Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                  With your input, this post could be even better 💗

                  Register Login
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  Online Users
                  I
                  itsbadjujuju
                  Forgot your key, lost your files, need a previous Lay Theme or Addon version? Go to www.laykeymanager.com
                  laytheme.com
                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Recent
                  • Tags
                  • Popular
                  • Users
                  • Search