Whats the best way to modify the backend UI a little bit?
Ive red saphire framework let you change things but I wonder If I would like to change the TAB styling for example how to do that.
Are there backend themes? To skin the backend?
This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
Whats the best way to modify the backend UI a little bit?
Ive red saphire framework let you change things but I wonder If I would like to change the TAB styling for example how to do that.
Are there backend themes? To skin the backend?
You can define a editor.css in your theme which is included in the backend. You could probably use this as a crude way of getting in and overriding css / images in the backend.
If you want to customize templates or do anything more drastic then your need to make a themes/yourtheme_cms/ folder and in that you should be able to override the css, templates.
Thanks Willr
So I create a /themes/myname_cms/ and copy all /images/ /css /templates from /cms/* inside that?
Hmm just tried this myself and it looks like the path to the css files are hardcoded, I thought the links should have been themedCSS but appears not. You can try doing that. If you don't have any luck use the editor.css to override it.
Hey Willr,
I'm not having any luck with this with 2.4 beta1. Is there any other way to set some custom CSS in the admin side? I need to apply 2-3 classes so nothing huge, but editor.css doesn't seem to get loaded in scope. For example,
body.CMSMain {
background: aqua;
}
doesn't show anything.
Thanks,
Wilson
Can the dev team make this non hardcoded and a setting in the config files?
So we can easily override this?
jorrie just had a look through the code and changing the css links to the themedCSS won't work since it'll include your themes main files but I have stumbled across another way to do it. LeftAndMain::init() has a extend() call (at least in 2.4) so you can override with a custom LeftAndMain extension.
// mysite/code/MyCustomLeft.php
<?php
class MyCustomLeft extends Extension {
public function init() {
Requirements::themedCSS('admin');
}
}
Then add the extension in your _config
// add to the mysite/_config.php
Object::add_extension('LeftAndMain', 'MyCustomLeft');
Will load an admin.css file from your theme.
Wow! Thanks Willr. I really appreciate that. I'm using 2.4, so this will be really valuable. Thx!!