WordPress.org

Plugin Directory

Add Admin CSS

Interface for easily defining additional CSS (inline and/or by URL) to be added to all administration pages.

Can I add CSS I defined via a file, or one that is hosted elsewhere?

Yes, via the "Admin CSS Files" input field on the plugin's settings page.

Can I limit what admin pages the CSS gets output on?

No, not presently. At least not directly. By default, the CSS is added for every admin page on the site.

However, you can preface your selectors with admin page specific class(es) on 'body' tag to ensure CSS only applies on certain admin pages. (e.g. body.index-php h2, #icon-index { display: none; }).

Or, you can hook the 'c2c_add_admin_css' and 'c2c_add_admin_css_files' filters and determine the current admin page content to decide whether the respective hook argument should be returned (and thus output) or not.

Can I limit what users the CSS applies to?

No, not presently. At least not directly. By default, the CSS is added for any user that can enter the admin section of the site.

You can hook the 'c2c_add_admin_css' and 'c2c_add_admin_css_files' filters and determine the current user to decide whether the respective hook argument should be returned (and thus output) for the user or not.

Does this plugin include unit tests?

Yes.

Requires: 4.1 or higher
Compatible up to: 4.4.2
Last Updated: 4 weeks ago
Active Installs: 9,000+

Ratings

4.8 out of 5 stars

Support

Got something to say? Need help?

Compatibility

+
=
Not enough data

0 people say it works.
0 people say it's broken.

100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
0,1,0
0,1,0
100,1,1