selfthinker / dokuwiki-plugin-loadskin

Change the skin/template/theme of DokuWiki - admins can select templates for pages or namespaces, users can select templates for the whole wiki
http://dokuwiki.org/plugin:loadskin
GNU General Public License v2.0
7 stars 6 forks source link

Template script.js does not work #3

Closed selfthinker closed 9 years ago

selfthinker commented 13 years ago

As reported by Jan Kreps 2011/03/16 12:38 on http://www.dokuwiki.org/plugin:loadskin#template_scriptjs_does_not_work_without_doku_tplinc :

I noticed small trouble with javascript loading. All lib/tpl//script.js should be loaded at the start. But because I commented out part of init.php definig DOKU_TPLINC as suggested, script.js in template directory does not get loaded. It's because DOKU_TPLINC constant is needed when list of scripts to include is generated. It is in lib/exe/js.php in function js_out().

selfthinker commented 12 years ago

Since DOKU_TPLINC has been deprecated, things have changed a bit (see splitbrain/dokuwiki@c4766956646b53ab644ec6ddbd17d9cba07cf872 and splitbrain/dokuwiki@81aca18e6e88c08386c11592dbf4650114aba04f).

I have just tried to fix it, but found the following problems:

So, with the current existing solutions it's not possible to make a template's script.js work. This needs either some changes in the core or some clever new solution I couldn't think of yet.

selfthinker commented 9 years ago

I found a solution, but only by changing the core, see splitbrain/dokuwiki#1130.

selfthinker commented 9 years ago

This is now fixed in the current development version of the core DokuWiki. But I will keep this issue open until a new stable release is out.

selfthinker commented 9 years ago

As there is a new release of DokuWiki now, this can finally be closed.