Not logged in. · Lost password · Register
Forum: General Help and Support Templates and Layout RSS
Icons not appearing in second template
I use a wiki with two (slightly) different templates. In one the icons identifying links (e.g. external weblink, email etc.) are not appearing.
Avatar
mdebraaf #1
Member since Sep 2018 · 7 posts · Location: Switzerland
Group memberships: Members
Show profile · Link to this post
Subject: Icons not appearing in second template
Hi there,

I use a wiki (latest version Greebo) with two (slightly) different templates using the LoadSkin Template Manager plugin.

The objective was to get different LOGOS per Namespace. To achieve that I have created two versions of the Dokuwiki template and placed these in the lib/tpl/ folder. By populating the /lib/tpl/template/images folder with the appropriate logo, and using the LoadSkin plugin, I managed to get a different logo per namespace.

This works fine (with some help obtained in this forum over here ;-) )

After a while, however, I noticed that in one of these templates (the one that I have slightly modified) the icons normally placed before an external web link (globe) or an email address (envelope) are not appearing. In the other namespace/template, these icons appear normally.

I have checked to see if there are differences between these templates, but I have not been able to identify missing files, different files.

Can someone give me pointers WHERE I have to look for differences?

thanks for any help here ...

regards, Michael

P.S. Happy New Year !
This post was edited on 2019-01-03, 22:09 by mdebraaf.
Avatar
Michaelsy #2
Member since Jun 2015 · 745 posts · Location: Düsseldorf, Germany
Group memberships: Members
Show profile · Link to this post
Quote by mdebraaf:
Can someone give me pointers WHERE I have to look for differences?

I think a very hot candidate are the CSS rules/files of the two templates.

HTH - Michael Sy.
By Patreon.com a few eurons can be fed into the code phasers of
the DokuWiki engine. Besides, Andi's posts are worth reading.
This post was edited on 2019-01-03, 23:42 by Michaelsy.
Avatar
mdebraaf #3
Member since Sep 2018 · 7 posts · Location: Switzerland
Group memberships: Members
Show profile · Link to this post
Hi Michael,

indeed I was coming to the same conclusion, although I have 'just copied' the DokuWiki template and have only changed the logo in the image folder. I cannot remember that I have tinkered with any CSS file ... as my CSS knowledge is zero ;-)

What I found out in the meantime is that when I check a webpage of the template that does not function properly, I see in the console that the email.png file is not found (as well as the page.gradient.png, search.png, external.link.png and toc.arrows.png).

When I check a page in the template that functions properly, I do not get these error messages.

Funny thing is that I cannot locate in any folder (of any template) the email.png file, while I can locate the toc-arrows.png and other png-files. I cannot find any difference between de image-folder of the templates.

I guess this email.png file etc. is part of the wiki as I have located it in the lib/images folder.

So why can one template access this file, while the other -copied/modified- template cannot?
Is this determined in a CSS file?

Ciao, Michael
Avatar
Michaelsy #4
Member since Jun 2015 · 745 posts · Location: Düsseldorf, Germany
Group memberships: Members
Show profile · Link to this post
A vague idea: Empty the caches of your browser and of DokuWiki.

Another vague idea: What's with the naming of the two templates? Is there a need for a different name within the template (that corresponds with the directory name of the template)? (I think so...)
By Patreon.com a few eurons can be fed into the code phasers of
the DokuWiki engine. Besides, Andi's posts are worth reading.
Avatar
mdebraaf #5
Member since Sep 2018 · 7 posts · Location: Switzerland
Group memberships: Members
Show profile · Link to this post
Hi Michael,

emptying of the browser cache - tried with no positive effect.
emptying Dokuwiki cache  - by re-save the configuration in the configuration manager, done - no positive effect.

Essentially I have three variances of the dokuwiki template, named:

1) Dokuwiki
2) Dokuwiki - Vesper
3) Dokuwiki - Tomfrost

The 'original' template with the Dokuwiki name is for the root and then two instances (with both different namings) for the two namespaces for which I organized a specific logo. In one of the namespace (DokuWiki - Vesper) all works well. In the other (DokuWiki -Tomfrost), it doesn't.

So I will look into naming, but my guess this is not the culprit...
Avatar
Michaelsy #6
Member since Jun 2015 · 745 posts · Location: Düsseldorf, Germany
Group memberships: Members
Show profile · Link to this post
Is your DokuWiki online? Do I have read access?
By Patreon.com a few eurons can be fed into the code phasers of
the DokuWiki engine. Besides, Andi's posts are worth reading.
Avatar
Michaelsy #7
Member since Jun 2015 · 745 posts · Location: Düsseldorf, Germany
Group memberships: Members
Show profile · Link to this post
In reply to post #5
Quote by mdebraaf:
emptying Dokuwiki cache  - by re-save the configuration in the configuration manager, done - no positive effect.

So that really the entire cache is deleted: Delete the entire content of the dir /data/cache

My experience: Only if deleting all the cache dir content wil empty all cached information.

Info for the cautious:  https://forum.dokuwiki.org/thread/2460
By Patreon.com a few eurons can be fed into the code phasers of
the DokuWiki engine. Besides, Andi's posts are worth reading.
This post was edited on 2019-01-05, 14:56 by Michaelsy.
Avatar
mdebraaf #8
Member since Sep 2018 · 7 posts · Location: Switzerland
Group memberships: Members
Show profile · Link to this post
Subject: Solved
Thanks for your suggestions ...

I solved this issue, but do not understand why it works.

I noticed that affected template pages (in the namespace) could not load the icon.png files (e.g. email.png). In the other namespace, there was no issue.

I then noticed by looking at the console (F12) in my Chrome browser, it was trying to load the png file from an image folder in the Wiki root directory. Cannot remember whether there was an empty image folder, or that I created an image folder there. As soon as I copied the incon.png files in that directory, they appeared also on the pages in the affected namespace.... problem solved.

I do not understand WHY this behaviour is like it is and whether this solution will survive a wiki update. It's very weird that when I make a copy of a template and the use Skinloader to assign a namespace to that template, the behaviour (looking for files) is changed ....
Avatar
Michaelsy #9
Member since Jun 2015 · 745 posts · Location: Düsseldorf, Germany
Group memberships: Members
Show profile · Link to this post
I do not understand WHY this behaviour is like

If you want to know that, the next step would be to explore the CSS-data that is received by your browser.

whether this solution will survive a wiki update

I think so, new files from unknown sources are not deleted, I suppose.
By Patreon.com a few eurons can be fed into the code phasers of
the DokuWiki engine. Besides, Andi's posts are worth reading.
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
Imprint
This board is powered by the Unclassified NewsBoard software, 20150713-dev, © 2003-2015 by Yves Goergen
Current time: 2019-03-20, 02:20:40 (UTC +01:00)