I have this plugin called Tiddly Remember by Soren Bjornstad. Basically I want a bunch of text to be shown as “Wikitag::tag::title”. I tried to do this by doing this:
[addsuffix[::[get[title]]]][tags[]addprefix[WikiTag::]]
or this:
[tags[]addprefix[WikiTag::]addsuffix[get[title]]]
However, it doesn’t work. I wonder what’s wrong. Can anyone help me or show me an alternative syntax of doing the same thing? I’m new to TiddlyWiki and have a beginner knowledge of programming.
This filter is not correct! You need to get title first and pass the result to addsuffix!
Where do you use this? Is it insdie a $list widget?
What do you want with tags[]?
This is an example of what I understand from your question:
<$list filter="[all[current]tags[]] "variable=thisTag>
<$text text={{{ "Wikitag::" [<thisTag>] "::" [<currentTiddler>] :and[join[]] }}} />
</$list>
Note to the input to tags[] and the string/var concatenation in filtered transclusion in "Wikitag::" [<thisTag>] "::" [<currentTiddler>] :and[join[]]
If you put this inside a tiddler (abs Operator) you will get
Wikitag::Unary Mathematics Operators::abs Operator
Wikitag::Filter Operators::abs Operator
Wikitag::Mathematics Operators::abs Operator
If what you want to do is display text in a specific way, a filter is not required. All you actually need is to transclude the fields you want.
Wikitag::{{!!tags}}::{{!!title}}
If you put the above into a tiddler called “Wikitag”, you can directly apply it as a template like this {{Tiddler||Wikitag}}.
I don’t know what a list widget is, but the documentation says that I should put it on this tiddler: $:/config/TiddlyRemember/TagMapping.
I want to get the tag/s of a tiddler where I wrote question-and-answer notes
So what I am trying to say is that I need a filter syntax of getting the tag and the title of tiddler in this format: WikiTag::[tag of the tiddler where I wrote the question-and-answer-notes]::[title of the tiddler where I wrote the question-and-answer notes].
To simplify, I want it in this format, WikiTag::[tag]::[title]
This syntax works (without the title)
[get[tags]addprefix[WikiTag::]]
but this does not:
[get[tags]addprefix[Wikitext::]addsuffix[[get[title]]]]
I think this is the answer but I do not know how to do this.
I am not familiar with TiddlyRemember, so I cannot be of more help! Just a quick look, it seems you need to pass a filter expression!
How about the following? Assuming that only one tag is used for each instance…
{{{ [<currentTiddler>get[tags]addprefix[Wikitext::]addsuffix[::]addsuffix{!!title}] }}}
or
{{{ [[Wikitext::]] [<currentTiddler>get[tags]] [[::]] [{!!title}] +[join[]] }}}
If you want the result to just show as plain text, you stick the above “filtered transclusions” inside a TextWidget:
<$text text={{{…}}} />
Thanks! the first and second code snippets work. However, I don’t know what to call this but it shows something weird. For example, let’s say tag = Algebra and title = Polynomials, it would show up as:
Wikitext::Algebra::Polynomials {{{ }}}.
However, removing the curly brackets from the filter snippet would make the {{{ }}} disappear. Would this give me some trouble in the future? Say if I have 1000 tiddlers.