template-by-name's People
template-by-name's Issues
PHP Warning: Declaration of action_plugin_templatebyname_findtemplate
- Ubuntu 16.04
- PHP 7.0.33
[Wed Jul 24 11:17:07.590538 2019] [:error] [pid 29010] [client xxx] PHP Warning: Declaration of action_plugin_templatebyname_findtemplate::register(Doku_Event_Handler &$controller) should be compatible with DokuWiki_Action_Plugin::register(Doku_Event_Handler $controller) in /var/www/dokuwiki/lib/plugins/templatebyname/action/findtemplate.php on line 0
e_template and e__template are both referenced to the file e_template.txt
When we use the editable prefix, all the prefixes before the actual filename are reduced to a single _.
So e~~_dirname will create a file with the name e_dirname.txt so does the e~dirname value too.
duplicated statements
A very minor issue, these lines are default set by DokuWiki at other places since some years. So it is not useful to set them again for this plugin.
if (!defined('DOKU_LF')) define('DOKU_LF', "\n");
if (!defined('DOKU_TAB')) define('DOKU_TAB', "\t");
if (!defined('DOKU_PLUGIN')) define('DOKU_PLUGIN',DOKU_INC.'lib/plugins/');
require_once DOKU_PLUGIN.'action.php';
Do not parse the template by this plugin, but by DokuWiki
The last two lines of the findtemplate.php seems for me the same as the default actions of pageTemplate()
( https://github.com/splitbrain/dokuwiki/blob/master/inc/common.php#L877 )
...
$event->data['tpl'] = io_readFile($event->data['tplfile']);
}
if($event->data['doreplace']) parsePageTemplate($event->data);
...
I guess this plugin can be simplified by removing them.
Additional advantage: when there is another plugin that like to set templatenames, and this plugin hasn't set them, that plugin keeps the possibility to do so.
Crashes HogFather RC2
The usual PHP warning has become a fatal error and now crashes dokuwiki. removing the plugin fixes the issue... but then you don't have the plugin anymore ;-)
error log says:
[04-Jun-2020 12:02:20 Asia/Singapore] PHP Fatal error: Declaration of action_plugin_templatebyname_findtemplate::register(Doku_Event_Handler &$controller) must be compatible with dokuwiki\Extension\ActionPlugin::register(Doku_Event_Handler $controller) in /home/wiki/lib/plugins/templatebyname/action/findtemplate.php on line 73
Thank you.
Issues with direcotry template in 2014-09-29 "Hrun"?
Im running the newest version of Doku- 2014-09-29 "Hrun", and having some issues, with what I think should be pretty easy.
I can get the file template to work __yourfilename.txt
but I cant get the directory template to work ~~yourdirectoryname.txt
. No matter where I put it, it doesnt seem to catch it.
MyProjectName
~~Solutions.txt
=> Not Working => template forProject 1.txt
underSolution 1
Solutions
__start.txt
=> Working => template for thestart.txt
underSolution 1
Solution 1
start.txt
Project 1.txt
Basically I want all files under the Solutions
directory to inherit from a template UNLESS it is named start. If its named start then I want it to inherit from another template.
Am I doing something wrong, or is there a compatibility issue?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.