#1 2025-07-04 03:37:04

windracer
Member
St. Pete, FL
2014-12-28
637

Override admin template?

I'd like to replace the "Quick Local Synchronization" link on the admin main page with a different link (specifically to an extension, in this case, AlbumPilot). This link is defined in U_QUICK_SYNC in admin/intro.php and then used in admin/themes/default/template/intro.tpl.

I can just directly edit the .tpl file and replace the link (which works perfectly) but I'd prefer to use a template-extension so this change is preserved during upgrades. But I don't see a way to override the admin template via template-extension.

Is what I'm trying to do possible?

Offline

 

#2 2025-07-04 13:09:23

Katryne
Member
Provence, France
2016-12-03
601

Re: Override admin template?

Pierrick answered me once about overriding the admin theme. But I do not know if it can help in your case. Below is how he solved my issue :

Pierrick : I know the LocalFiles Editor can't change the CSS for the administration. But here is a trick. Use [extension by ddtddt] Add < head > Element instead with :

.permitActionItem {margin-left: 30px; width: 800px;}
.permitActionItem .selectize-control.single.plugin-remove_button {width: auto !important;}
.permitActionItem .selectize-input.items.full.has-options.has-items {width: 800px !important; line-height: 23px;}

and you're good. No need to re-implement it after each Piwigo update.

Last edited by Katryne (2025-07-04 16:51:47)


https://album.chauvigne.info/ v.16.4  PHP: 8.2.29
Système d'exploitation: Linux - Hébergeur 1&1-Ionos - MySQL: 5.7.42
Bibliothèque graphique: External ImageMagick 6.9.11-60

Offline

 

#3 2025-07-04 16:45:35

windracer
Member
St. Pete, FL
2014-12-28
637

Re: Override admin template?

Interesting idea but yeah, I don't think that would work since it only allows you to make changes to the head tags and not a link on the template/page itself.

Offline

 

#4 2025-07-04 16:54:43

Katryne
Member
Provence, France
2016-12-03
601

Re: Override admin template?

That's pure css : it did modify the display width of the maps on admin side. I don't think its about the head tags, despite the mod's name.


https://album.chauvigne.info/ v.16.4  PHP: 8.2.29
Système d'exploitation: Linux - Hébergeur 1&1-Ionos - MySQL: 5.7.42
Bibliothèque graphique: External ImageMagick 6.9.11-60

Offline

 

Board footer

Powered by FluxBB