Hello,
i want to change the manager theme, and i change only header.tpl and introduce mycss.css (insert to header).
I created a new directory (mytheme) inside the template manager and inserted the modified (header.tpl) and added (css/mycss.css) files, after i change manager_theme settings to mytheme, as the guide says (i’m on 3.x version) https://docs.modx.com/3.x/en/building-sites/client-proofing/custom-manager-themes
For to work, however, I have to copy the entire default folder into mytheme folder and then replace the custom files (header.tpl)
Is this okay?
I understood that it was enough to copy only the modified files
I solved this even if it contradicts the linked guide.
But
in fresh install with no change, no extra, nothing. If i change theme only width header.tpl in new cuatom folder, this is the result
For me it’s ok.
The problem of the logo in the manager remains.
In header.tpl, on line 98 (<img src="{$_config.manager_url}templates/{$_config.manager_theme}/images/modx-icon-color.svg" title="{$_config.site_name|strip_tags|escape}">) it would be enough to check if it exists or put the default one, or something similar.
In login i don’t have problema.
I have no problems login.tplin even though @ halftrainedharry mentioned some
This is the only case where anything in the CMS has ever referenced the $_config.manager_theme in a path that I can find. In 2.x it was a background image:
I’m not sure the best way to have a theme fallback here. Smarty and defaults are not something I’m familiar with. I don’t know if it would work anyway since the custom theme value will be not NULL and as such the variable will have a value. I feel there must be a reference to the Manager Theme globally and those themes should derive the structure from that.
If I understand what you mean, you are completely right.
But if you want to quickly move on to 3.1.1., here, just for an src link, one “if” may be fine.
Or change the guide, inserting to also copy “templates/default/images/modx-icon-color.svg” in new custon theme, to avoid creating misunderstandings.
if the logo is available in the custom manager theme directory and then set a placeholder (with $this->setPlaceholder() and use a variable in the Smarty template instead of using {$_config.manager_url}templates/{$_config.manager_theme}/images/modx-icon-color.svg:
On the manager login page, there is a similar problem with the MODX logo here
and the background image (4 lines above), where you had to check the availability of these images in the custom manager theme folder.
These are more code changes than I’m personally willing to make. So I did not include this in my PR (which only deals with the dashboard widgets).
I’d suggest copying the images to your custom manager theme folder, using custom images or just changing header.tpl and login.tpl in your custom manager theme.
Yes, i see, the problem in login page, sorry.
In my custom manager theme add the folder
custom/images/
widh
modx-logo-color.svg
and
login/default-background.jpg
and all in login and dashboard it’s ok.
Thank’s