3

How can I preserve changes to civicrm.css when I update civicrm?

For example the combo box for Event Fee(s), Registration Fee is too narrow - the amounts are cutoff on the right. I want to preserve my width setting of 20em.

4

If you use a custom CSS style sheet, you avoid the scenario you mention of losing modifications to your CSS upon upgrade. From the top menu, go to Administer > System Settings > Resource URLS and use the Custom CSS URL field. Its help text reads:

You can modify the look and feel of CiviCRM by adding your own stylesheet. For small to medium sized modifications, use your css file to override some of the styles in civicrm.css. Or if you need to make drastic changes, you can choose to disable civicrm.css completely.

You can put the file anywhere you'd like (so you would put it outside of the file structure that will get replaced when you upgrade CiviCRM; just specify its location in the field). That custom CSS file gets loaded after civicrm.css so as long as you've selected the proper components with your IDs, classes, etc. your custom CSS will take precedence over Civi's.

  • 1
    Just what I needed -- explanation in plain English. – P a u l Feb 22 '16 at 2:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.