• Resolved utfred2

    (@utfred2)


    Hi – Great theme, thank you!
    I use some html to create a ‘buy’ button for my future Spanish store, specifically:
    <input class=”button” type=”submit” value=”Añadir a carrito “/>
    This creates a default button with the right text in it; I found out how to change its color in the customizer, but the padding around the text is quite big. How to change that? I am not great with custom CSS… Thanks in advance

Viewing 4 replies - 1 through 4 (of 4 total)
  • Do you want it for just that button or all buttons across the site? Having such a generic class name as button for that may make it a bit more difficult to target it specifically with some CSS.

    You may want to do something like class="button buy-button" so it is easier targeted while still getting the default styling. From there you could try something like

    .single .buy-button a {
       padding: 0px;
    }

    To see if that works, though if you’re able to provide a link to the page with the button on it, I can most likely provide you with something that’ll work for sure.

    Thread Starter utfred2

    (@utfred2)

    Thank you so much for your quick response. I tried it and it does make a difference unfortunately.
    I tried this but it does not work either…
    .single .button
    input[type=”submit”]{
    padding: 0px;
    }

    Here is the link to my page in progress, you can’t miss the buttons I am talking about! We use an outside cart provider, so we write all the code for the purchasing process on that page, hence my attempt with the “submit input” above

    https://ispinnakers.es/tienda-de-spinnaker-asimetrico/

    e.g. of code I inserted for the bags (3rd column on the right, top row):

    <form accept-charset=”utf-8″ action=”https://isails.foxycart.com/cart&#8221; method=”post”>
    <input name=”template_set” type=”hidden” value=”it-EUR”/>
    <input name=”name” type=”hidden” value=” Bolsa de spinnaker, Rojo “/>
    </select>

    <select name=”Tamaño”>
    <option value=””> Tamaño</option>
    (codes for a bunch of option values)

    </select>
    <br/>
    <input class=”button” type=”submit” value=”
    Comprar”/>
    </form>

    Thanks!

    Hi, this CSS appears to target it, just add into Appearance->Customize->Additional CSS

    .wp-block-columns .wp-block-column form input:last-child {
        padding: 5px;
    }

    You can adjust the 5px value to your liking.

    Thread Starter utfred2

    (@utfred2)

    It works like a charm, you are a CSS wizard! – Thank you very much

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Reduce padding around default button’ is closed to new replies.