How to link a tag to a tiddler of a different name?

93 views
Skip to first unread message

Harry

unread,
Jul 23, 2021, 7:39:39 PM7/23/21
to TiddlyWiki
Hi all,

I have a question that I think might be simple but have not been able to figure out as a novice. I have attached a tag, say "CBC", to all entries who are a member of the congressional black caucus. When I click the CBC tag in a given tiddler, the pop-out would show a clickable line "CBC" which would automatically redirect to an yet-uncreated entry "CBC" . But I already have a list tiddler named "List of all congressional black caucus members" and I want to make the clickable line "CBC" redirected to this longer-named tiddler. Is there a simple way that I can do it? Thanks a lot!

Best
Harry

TW Tones

unread,
Jul 23, 2021, 8:02:52 PM7/23/21
to TiddlyWiki
Harry,

In this case the tiddler CBC is a tiddler for the tag. The quick solution is to place in CBC [[List of all congressional black caucus members]] and perhaps also <<tag CBC>> Even add "List of all Congressional Black Caucus members (CBC)."

If someone is familiar that CBC is a tag they can make use of the tag to add items or reorder with tag pill. If they do not understand what CBC is about then by opening the "tag tiddler" they see a link to its tiddler or expanded name.

Of course we could automate and doo more but I am not sure it would occur often enough to bother.

Regards
Tones

Harry

unread,
Jul 23, 2021, 8:52:25 PM7/23/21
to TiddlyWiki
Hi Tones,

Thanks for your help. This is certainly an easy solution. Though in my case, I have a few dozens of such tags with short acronyms but longer full names. So I wonder if there's another way that could allow a click on the tag tiddler to be auto-redirected to another tiddler. This would save a click and also help me not opening too many tiddlers after clicking on these tags. If it's too much hassle, then never mind, thanks again!

Best
Harry

TW Tones

unread,
Jul 23, 2021, 9:43:36 PM7/23/21
to TiddlyWiki
Harry,

It would not be wise to do it on the first click of the tag as access to the tag pill dropdown is important.

I have a small set of macros that extend the "tag pill dropdown". I could make a variation that looks for say a "redirect" field in a "tag tiddler" and displays that in the "tag pill dropdown" for which a click would open the tiddler.

Perhaps the redirect field like this [[Congressional Black Caucus|List of all Congressional Black Caucus members]]

So for the CBC tag click, and you will see "Congressional Black Caucus" and a click would navigate to [[List of all Congressional Black Caucus members]]

What do you think?

Tones

Harry

unread,
Jul 23, 2021, 11:13:14 PM7/23/21
to TiddlyWiki
Hi Tones,

Thanks for your help. I think what you suggested is what I want. I don't mean to skip the tag pill dropdown, but want to make the first click after the dropdown to be redirected to a different tiddler, (See the blue shaded line in the pic attached). If there's a way to do so, I would really appreciate your help with the specific steps on coding (I'm extremely novice to this), thanks again!

Best
Harry
CBC.png

TW Tones

unread,
Jul 24, 2021, 9:20:06 AM7/24/21
to TiddlyWiki
Harry,

I will have a look tomorrow, after I get in a Queue for a covid test, since an employee at my local supermarket has tested positive when I was there. If you don't hear from me feel free to send a private message.

Of course anyone else can help Harry.

Tones

Harry Reid

unread,
Jul 24, 2021, 8:36:09 PM7/24/21
to tiddl...@googlegroups.com
Thanks a lot, Tones! Hope your test end up fine.

Best
Harry

TW Tones <anthony...@gmail.com> 于2021年7月24日周六 上午9:20写道:
--
You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/-hIdxL3nv-Y/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/8b0838e9-33ce-4df8-8aac-1c92b227a271n%40googlegroups.com.

TW Tones

unread,
Jul 24, 2021, 10:25:57 PM7/24/21
to TiddlyWiki
Harry,

Find attached a "Quick and Dirty solution" drop this on your wiki, or tiddlywiki.com to test. 
  • After importing tag a tiddler for example CBC
  • Now click on the CBC tag and select its name CBC to open the tag tiddler
  • Now edit this tiddler and place the following
    __[[Congressional Black Caucus|List of all Congressional Black Caucus members]]__
  • Save and close. Now click on the CBC tag pill whereever you find it.
  • If you click on CBC you see and can click on Congressional Black Caucus it will open " List of all Congressional Black Caucus members"
OK the quick is obvious, but why dirty?
  • If a tag tiddler already contains content for another reason it will be visible in the dropdown, it could be messy.
    • We should perhaps use another field than text.
  • Strange artefact's occur because of the styles on items in the dropdown that is why I used underline to make it look like the link it is.
  • The outline appears even when the text is empty, yet its important to delineate it.
Regards
Tones
tag-transclusion.json

Harry

unread,
Jul 24, 2021, 11:14:13 PM7/24/21
to TiddlyWiki
Hi Tones,

This works perfect in my case! Thanks a lot for your patience and help!!

Best
Harry

TW Tones

unread,
Jul 24, 2021, 11:26:33 PM7/24/21
to TiddlyWiki
Great, glad to help.

Tones

Reply all
Reply to author
Forward
0 new messages