Listing tiddlers that use me as a tag, in a template

Hi, I am using TW 5.1.19, and have a question about lists of tiddlers with a tag.

Here’s the scenario: I want to create a journal tiddler (say ‘20220919’), and want to have in the tiddler a list of tiddlers that use the journal title (‘20220919’) as a tag.

I currently accomplish this by manually writing

{{{ [tag[20220919]]}}}

in the journal tiddler.

What I want is to add something like {{{ [tag[this tiddler]]}}} to the journal template, so that this happens automatically.

Is there a way to accomplish this?

Thanks!
Rodrigo

I am using TW 5.1.19

That is a very old version of TW! (20th December 2018).

The current version is 5.2.3 (2nd August 2022), and includes MANY feature improvements and significant performance enhancements. I strongly recommend upgrading (see https://tiddlywiki.com/upgrade)

What I want is to add something like {{{ [tag[this tiddler]]}}} to the journal template, so that this happens automatically.

In the $:/ControlPanel > Info > Basics tab, in the “Text for new journal tiddlers” input area, enter:

{{{ [tag<currentTiddler>] }}}

enjoy,
-e

1 Like

Welcome Rodrigo,

The other way is to create tiddler tagged $:/tags/ViewTemplate containing;

<$list filter="[tag[Journal]]" variable=nul>
   {{{ [tag<currentTiddler>] }}}
</$list>

Optionally add the field “list-after” with the value $:/core/ui/ViewTemplate/body

So as long as a tiddler is tagged “Journal”, the items tagged with the current tiddler will be listed below the main body of the tiddler.

  • Eric’s case uses the New Journal tiddler template and will include this {{{ [tag<currentTiddler>] }}} in every New Journal tiddler.
  • This solution uses the view template for every tiddler tagged “Journal”, new or existing.

I tend to place other things inside this kind of view template like this;

<$list filter="[tag[Journal]]" variable=nul>

  !!Journal entry <$view field=created format=date template="DDD"/>
   :Created: <$view field=created format=relativedate />
   {{{ [tag<currentTiddler>] }}}
</$list>
  • When you change this, it is automatically visible on all Journal tiddlers, past or present.
2 Likes

OMG! When was this feature added? Or has it been always there and I was blind to it?

I added a tiddler and then edited new-journal action to use it.

<$action-sendmessage $message="tm-new-tiddler" title=<<journalTitle>> tags=<<journalTags>> text=<<journalText>>/>

If only I had know it is so simple to customize journal’s template. :slightly_frowning_face:

2 Likes

Thank you Eric! Sorry for the delay in replying, I was away for a week.

I did try to upgrade, but the resulting file didn’t open (the screen was white), and I didn’t investigate why yet.

Your solution worked beautifully, thank you so much!

Rodrigo