Changing color of read-only text

  • Profile Image
    Asked on May 24, 2016 at 08:34 AM


    I have a few read-only fields, of which I would like to change the color to grey - without affecting the color for all the other input fields.

    Can this be done, and if so, how?


  • Profile Image
    Answered on May 24, 2016 at 10:47 AM

    Yes, you can do that by adding this CSS to your form:

    [readonly="true"] {
        background-color: lightGray;

    You can add it based on the steps mentioned here: Inject Custom CSS Codes

    Do of course let us know how it goes and if you have any questions in regards to the same.