Creating tabs with multiple variables in name

102 views
Skip to first unread message

Emmanuel Calvet

unread,
Oct 15, 2018, 7:12:43 PM10/15/18
to tiddl...@googlegroups.com
Hi, I have trouble trying to create new tabs with a name containing many variables. 

So my problem is the following :

I have a tiddler which possess two fields : released=ddd, and author=xxx.

When I do that
<$set name=Résumé value='{{!!released}} {{!!author}}-Résumé'>
<<Résumé>><br/>
<$set name=Notes value='{{!!released}} {{!!author}}-Notes'>
<<Notes>><br/>
<br/>

I obtain this :

ddd xxx-Résumé
ddd xxx
-Notes


Then I've tried to create a tab, with both variables

<<tabs "[<Résumé>] [<Notes>]" "Click the little link">>

And this is what it displays :

display.png






I guess this comes from the way I write the value='{{!!released}} {{!!author}}-Notes',
Because, if I change my code and put only one variable inside each name

<$set name=Résumé value={{!!released}}>
<$set name=Notes value={{!!author}}>

Then 

<<tabs "[<Résumé>] [<Notes>]" "Click the little link">>


Displays the variables correctly 
display2.png





So I've run out of ideas, and I am wondering what is the way to write it properly ?

Thanks for your help !



Mark S.

unread,
Oct 15, 2018, 7:39:15 PM10/15/18
to TiddlyWiki
You can't "glue" the outputs of transclusions together that way, In the past I would have said to use a macro, but with the <$wikify> widget you can now, sometimes, put results together in the way you want:

<$wikify name=Résumé text='{{!!released}} {{!!author}}-Résumé'>
<$wikify name=Notes text='{{!!released}} {{!!author}}-Notes'>
<<tabs "[
<Résumé>] [<Notes>]" "Click the little link">>

</$wikify>
</$wikify>

Good luck
-- Mark

Jeremy Ruston

unread,
Oct 16, 2018, 5:15:01 AM10/16/18
to tiddl...@googlegroups.com
Hi Mark, Emmanuel,

You can't "glue" the outputs of transclusions together that way, In the past I would have said to use a macro, but with the <$wikify> widget you can now, sometimes, put results together in the way you want:

<$wikify name=Résumé text='{{!!released}} {{!!author}}-Résumé'>
<$wikify name=Notes text='{{!!released}} {{!!author}}-Notes'>
<<tabs "[
<Résumé>] [<Notes>]" "Click the little link">>

</$wikify>
</$wikify>


Just to point out a pitfall of that approach -- the tranclusions {{!!released}} and {{!!author}} will be wikified, so if you have an author Mary McManus, then their second name would be turned into a link.

If you want to display those fields without wikifying them, then use the <$text text={{!!released}}/> or <$view field="released"/> widgets.

Best wishes

Jeremy


--
You received this message because you are subscribed to the Google Groups "TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/689b913a-55a9-49c6-9988-4a848c0a348b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Emmanuel Calvet

unread,
Oct 16, 2018, 6:36:51 PM10/16/18
to tiddl...@googlegroups.com
Okay thank you both for your help, 

I finally, found another way by using this pluggin :

http://tobibeer.github.io/tw5-plugins/#setvars

But the wikify is definitely a good one ! :)

Emmanuel
Reply all
Reply to author
Forward
0 new messages