Greetings,
I use the modus theme, and want to do some header modifications. So I made a copy of header.tpl, called my-header.tpl in the local files editor, and substituted it in the template extesion settings.
Surprise. Even without modifications, this setup fails.
The cause seems to be the missing file theme.css in the modus main directory and the following lines in (my-)header.tpl.
{foreach from=$themes item=theme}
{if $theme.load_css}
{combine_css path="themes/`$theme.id`/theme.css" order=-10}
{/if}
{if !empty($theme.local_head)}
{include file=$theme.local_head load_css=$theme.load_css}
{/if}
{/foreach}
What I don't understand is, why do these lines create an issue in my-header.tpl, but not in header.tpl, when these two files are identical?
Environment
Piwigo 14.4.0
Installed on 26 April 2024, 1 month 1 week ago
Operating system: Linux
PHP: 8.3.6 (Show info) [2024-06-03 23:18:18]
MySQL: 10.6.18-MariaDB [2024-06-03 23:18:18]
Graphics Library: GD bundled (2.1.0 compatible)
Cache size 0 Mo calculated 1 month ago
Activated plugin list 4
Admin Tools
Contact Form
Language Switch
LocalFiles Editor
Piwigo URL: http://www.catsofai.com
Offline
What changes want? In the Theme Modus, you can also make many adjustments via the css in the Local Files Plugin.
Take a look here, i use the Modus Theme also: https://archiv.giel-bildwelten.de/
Many greetings
Oliver
Offline
I need to add links to the header. You've done the same. It works fine in the Desktop versionof the site via adding banner code.
However, the mobile version doesn't show the header links.
It is absolutely important to have them there too, so I need to go into the header source code. It can't be done by css.
It might also be better to address the bug in template extension than to look for a workaround. A workaround would still be good for a quick fix, but the missing file template.css breaks the whole concept of template extensions.
Offline
If you can make a screenshot on my side, what they mean exactly, then I can say how I implemented it.
Offline
However, I know how to implement this. All you've done is disable the mobile theme to get the links on mobile devices. If you can let me know how to do that, that'd be a good workround for my issue.
The mobile theme is much nicer though for mobile devices. It'd be a shame losing it.
So in any case the original issue remains. Why does replicating header.tpl cause issues?
Offline
This here should not be happening from replicating header.tpl. The cause is, as I said, in the source code in my first post.
Offline
I use only the normal Modus Theme, not a Mobile Theme.
The code of the Navigation is simple html, write in the menue "basic configuration"
<a href="https://example.de/" target="_top">
<img style="display: block; margin-top: 8px; margin-left: auto; margin-right: auto;" src="https://example/logo.png" alt="alttext">
</a>
<div class="navigation navigation-page">
<nav class="navigation-item-list">
<a href="https://example.de/index.html" target="_top">Bildwelten</a>
<a href="https://example.de/leistungen/index.html" target="_top">Leistungen</a>
<a href="https://example.de/logbuch/index.html" target="_top">Logbuch</a>
<a href="https://example.de" target="_top">Bildarchiv</a>
</nav>
</div>
The switch of the navigation on smaler screen makes the browser. on my piwigo page, i make no optimation to mobile.
on the header.tpl i make only optimation for the meta name robots tag (index, folow) not for the layout.
Offline
Thanks! The Modus template just isn't mobile friendly at all. So all of that are just workarounds...
I've switched to Bootstrap Darkroom to avoid any hassle with the Modus template now.
Offline
Yes the Modus is a light and clean Template but not good for Mobile.
Offline