Use of multiple templates

41 views
Skip to first unread message

Poul

unread,
Feb 11, 2012, 5:56:53 PM2/11/12
to TiddlyWiki
It's nothing new that giewiki supports alternative edittemplate and
viewtemplate attributes to be defined for specific tiddlers. Prior to
the 1.15.8 release, there wasn't however a nice way to specify which,
making it effectively a developer-only feature. The new release adds a
generic field editing facility (available only to admins and page
owners) that lets you set these attributes through the standard UI. I
realize that this is only a step on the way; having defined an
alternative template, you would naturally want to easily instantiate
tiddlers based on it.

The primary reason I write is however to float a different idea that
came up in the process. The way I have implemented the field editor is
as separate pseudo-tiddler, in order to allow it to be opened through
a tiddler link of the form "fields:TiddlerName", and it occurred to me
that it might be a useful feature if you could apply any template to
any tiddler through a link pattern like templatename:TiddlerName. A
use case might be to give different people access to the same tiddlers
through different templates. But then again, this could be totally
redundant, if there are better ways to do the same thing - what do you
think..?

:-) Poul
http://giewiki.appspot.com

PMario

unread,
Feb 12, 2012, 5:06:34 AM2/12/12
to TiddlyWiki
On Feb 11, 11:56 pm, Poul <poul.stauga...@gmail.com> wrote:
> ... a tiddler link of the form "fields:TiddlerName", and it occurred to me
> that it might be a useful feature if you could apply any template to
> any tiddler through a link pattern like templatename:TiddlerName. A
> use case might be to give different people access to the same tiddlers
> through different templates. ...
I think this is a very intersting idea. So you tweak the link renderer
according to the "logged in" user. right?

At the moment, you have to put some logic into a ViewTemplate, with
macros like hideWhen, showWhen or showWhenTagged. The advantage is,
you have everything in one place. The disadvantage is, it gets quite
bulky very fast.

-m

Poul

unread,
Feb 12, 2012, 9:37:18 AM2/12/12
to TiddlyWiki
On 12 Feb., 11:06, PMario <pmari...@gmail.com> wrote:
> I think this is a very intersting idea. So you tweak the link renderer
> according to the "logged in" user. right?

It's still just an idea; just how different users would see different
links would probably be application-dependant.
I haven't actually done anything to facilitate this, but I imagine I
would use Eric's InlineJavascriptPlugin to generate the appropriate
links based on whatever rules apply.

It could also be as simple as mailing a link with the right tiddler
link after the # , only that doesn't work with my current solution,
which works in onClickTiddlerLink().

/Poul

TonyM

unread,
Feb 12, 2012, 8:06:57 PM2/12/12
to tiddl...@googlegroups.com
I may have this wrong but I assume you have considered;
http://www.TiddlyTools.com/#TaggedTemplateTweakInfo

I use it for what sounds like what you are after using tags.

Poul

unread,
Feb 13, 2012, 5:48:07 AM2/13/12
to TiddlyWiki
What I have already achieves the same result. What I'm proposing is
rather different: That the URL should be able to specify both the
template and the data. Not appropriate in the normal case, but it
could have specific applications.

/Poul

On Feb 13, 2:06 am, TonyM <anthony.mus...@gmail.com> wrote:
> I may have this wrong but I assume you have considered;http://www.TiddlyTools.com/#TaggedTemplateTweakInfo<http://www.tiddlytools.com/#TaggedTemplateTweakInfo>

Måns

unread,
Feb 14, 2012, 3:51:16 AM2/14/12
to TiddlyWiki
Hi Poul

> What I have already achieves the same result. What I'm proposing is
> rather different: That the URL should be able to specify both the
> template and the data. Not appropriate in the normal case, but it
> could have specific applications.

http://linux-abc-noter.tiddlyspot.com/#txtTheme:Outline Puppy-abc

Paramifiers do work with standard TW core already... (No need for
TaggedTemplateTweak ...)

I believe it should say so here: http://www.tiddlywiki.com/#StartupParameters
- however it doesn't...

Cheers Måns Mårtensson

Reply all
Reply to author
Forward
0 new messages