Payment widget selected product won't change background color

  • ReDefiners
    Asked on March 28, 2024 at 5:47 PM

    Hi,


    I need help with my payment widget. I injected a CSS code to change the color of the selected product, code I found on your website. However, as you can see, the selected product doesn't change at all.

    How can I make it work?

    It only works when I activate selection of multiple products on the widget settings.


    https://form.jotform.com/240867174101149

  • Afzal JotForm Support
    Replied on March 28, 2024 at 6:40 PM

    Hi Chantelle,

    Thanks for reaching out to Jotform Support. I'll need a bit of time to look into this. I'll get back to you as soon as I can. 

    Thanks for your patience and understanding while we look into this.

  • Afzal JotForm Support
    Replied on March 29, 2024 at 9:28 AM

    Hi Chantelle,

    I appreciate your patience. I understand you are looking to change the background color when an option is selected. This can be done by adding custom CSS to your form. Check out the steps below to see how it's done:

    • Open your form in Form Builder and click on the blue Paint Roller icon on the right side of the screen.
    • Under the Styles tab, paste the code below into the Inject Custom CSS area.
    /*Change selected product background - 13381901*/
    .form-product-item .p_checkbox input[type="radio"]:checked ~ div.select_border {
        border: 1px solid #2e69ff;
        background-color: #ff000038 !important;
    }

    .form-product-item .p_checkbox input[type="radio"] ~ div.select_border {
        border-radius: 4px !important;
    }

    .form-product-item .p_checkbox .select_border {
        width: 626px !important;
        height: 50px !important;
        top: -6px !important;
        left: 21px !important;
    }

    .form-product-item .p_checkbox .checked {
        border: 1px solid #2e69ff00 !important;
        background-color: #2e69ff00 !important;
    }

    .select_border, 
    .select-area, 
    #productSearch-input, 
    .select-content, 
    #coupon-input {
        background-color: #fff0 !important;
    }
    • Now find the below line of CSS code in your custom CSS section and remove it(Line 255-277):
    .p_col {
        display : none;
    }

    Here's what the result will look like:

    Payment widget selected product wont change background color Image 1 Screenshot 20

    Here's the cloned version of the form that you can test.

    Please give it a try and let us know how it goes. 

 
Your Answer