CSS Button colours

This topic contains 7 replies, has 4 voices, and was last updated by  Alex Howes 6 years, 3 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #1981

    Alex Howes
    Buyer
    Post count: 175

    Hello,

    For some reason CSS isn’t getting through on WP invoicing pages. E.g. I’m trying to change the button colours on the invoice print page using the following code:

    
    
    .btn-sm { 
       background-color: red; 
    }

    CSS also isn’t working on the stripe modal box at checkout:

    
    
    .Button {
       background-color: red;
    }
    #1982

    Guust
    Moderator
    Post count: 29970

    Can we please have admin login details and a link to the page you are referring to?
    Thanks

    #1983

    Alex Howes
    Buyer
    Post count: 175
    This reply has been marked as private.
    #1984

    Kor
    Moderator
    Post count: 16516

    Hi Alex,

    Thanks for your reply. Below is the correct custom CSS code to change this. Could you give it a try?

    
    
    .btn-warning {
        color: #fff;
        background-color: #f0ad4e;
        border-color: #eea236;
    }
    
    .btn-primary {
        color: #fff;
        background-color: #337ab7;
        border-color: #2e6da4;
    }
    #1985

    Alex Howes
    Buyer
    Post count: 175

    Hi Kor,

    For some reason the CSS is not coming through.

    Alex

    #1986

    Kor
    Moderator
    Post count: 16516
    This reply has been marked as private.
    #1988

    Patrik
    Moderator
    Post count: 1971

    Hi,

    Try to add following code in your current active theme’s functions.php file and let me know if it works for you or not:

    
    
    add_action( 'wpinv_invoice_print_head', 'wpinv_modified_style' );
    function wpinv_modified_style(){
        ?>
        <style type="text/css">
            body.wpinv-print .btn-sm {
                background-color: red;
            }
        </style>
        <?php
    }

    Stripe popup CSS can’t be changed as it is generated by stripe and loaded in iframe while making payment.

    Regards,
    Patrik

    #1991

    Alex Howes
    Buyer
    Post count: 175

    Great, thanks Patrik! 🙂

Viewing 8 posts - 1 through 8 (of 8 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket