change color of the dropdown field options

  • Profile Image
    RT
    Asked on June 18, 2019 at 11:51 AM

    I want to change the color of the dropdown menu field, to match the color of the option chosen in the options list. Do you have any idea how to do this? I'm clueless!



    This is a re-post of a comment on How to Inject Custom CSS Codes

  • Profile Image
    Richie_P
    Answered on June 18, 2019 at 01:45 PM

    We can change the colors of the dropdown option by using custom CSS and nth:child selector.

    Here is a sample CSS:

    option:nth-child(2) {

     background: red;

    }
    option:nth-child(3) {

     background: blue;

    }
    option:nth-child(4) {

     background: green;

    }
    option:nth-child(5) {

    background: yellow;

    }

    Guide:https://www.jotform.com/help/117-How-to-Inject-Custom-CSS-Codes

    Screenshot:

    Sample Form:https://form.jotform.com/91685375251968

    Please give it a try and let us know if you need further assistance.