[I have moved the old content of this page to the hopefully better named RevisionSelectorVariable topic. The attachment belongs there. ] (
AndreaSterbini - 01 Sep 2000)
Proposal: move templates to topics in the administration web and use INCLUDE
In my home TWiki installation I am trying to move sections of the templates in the administration web (Twiki) so that I can easily edit them.
In one of my tests I have splitted the view.tmpl template in 3 files:
- a Twiki.TopBar topic that contains the top part of the original template
- a Twiki.BottomBar topic that contains the bottom part of the original template
- a view.tmpl file that contains just something like:
...
%TOPTEXT%
| %LEFTTEXT% |
%TEXT% |
%RIGHTTEXT% |
%BOTTOMTEXT%
In my TWikiPreferences I have added the lines:
* Set TOPTEXT = %INCLUDE{"%TWIKIWEB%.TopBar"}%
* Set LEFTTEXT = %INCLUDE{"%TWIKIWEB%.LeftBar"}%
* Set BOTTOMTEXT = %INCLUDE{"%TWIKIWEB%.BottomBar"}%
* Set RIGHTTEXT =
Using the modifications in
BetterTWikiTagTemplateProcessing all works almost fine
but :
- some variables are not replaced (e.g. the %REVISION...%)
- all wiki links in the text refer to the web Twiki, i.e. to the web originating the included file
Revision info of the enclosing topic
I would like that the %REVISION...% variable is handled in the same way other variables are. A way could be to add that variable to the variables collected in the preferences topics.
(this brings me to thinking that some variable should not be overridable by web/user preferences, shoud we open a
SecurityAndVariableOverriding topic?)
References to the origin web of included topics
I would like that the text substituted in the included file refers to the
destination web .
In other way of usage the includer would probably like to keep the
originating web references. (see
ReferencesInIncludedTopics)
--
AndreaSterbini - 01 Sep 2000
Another way to solve this is to introduce
WebBasedTemplateMaintenance.
--
PeterThoeny - 03 Sep 2000
Topic revision: r9 - 03 Sep 2000 - 20:23:46 -
PeterThoeny