Site logo

[Resolved] Add to Cart Shortcode from Woocommerce

Home Forums Support [Resolved] Add to Cart Shortcode from Woocommerce

Home Forums Support Add to Cart Shortcode from Woocommerce

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #2472177
    Paul

    Woocommerce’s [add_to_cart id=”16521″] includes a lot of styling I am trying to remove.

    https://www.sandandsteelfitness.com/test/

    I would like to remove the border, padding, button, etc. Basically I just want to display the regular and sale price.

    I am struggling to fix this, since it seems the styling code is affecting element.style and I don’t know how to select that with standard css overrides.

    Thank you!!!

    #2472300
    David
    Staff
    Customer Support

    Hi there,

    those elements have inline styles ie. there is a style=" attribute in its HTML, thats what you see as the element.style.
    You can use CSS to override them but you need to use !important like so:

    .add_to_cart_inline {
        border: 0 !important;
        padding: 5px !important;
    }
    #2473569
    Paul

    Thank you… this code works great.

    -Paul

    #2474865
    David
    Staff
    Customer Support

    You’re welcome

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.