On Monday, June 29, 2020 at 9:56:19 AM UTC-7, David wrote:
>
> This code almost gets me there, but it renders the list of trackin numbers
> as space-delimited instead of comma. I wasn't able to find a way to
> find/replace.
> <$set name="myVariable"
> filter="[tag[IncomingItem]!has[date_received]has[tracking_number]get[tracking_number]]">
> <a href={{{[<myVariable>addprefix[https://t.17track.net/en#nums=]]}}}
> >Track All</a>
> </$set>
>
This one is easy! Add "join[,]" to the end of your filter, like this:
<$set name="myVariable"
filter="[tag[IncomingItem]!has[date_received]has[tracking_number]get[tracking_number]join[,]]">
<a href={{{[<myVariable>addprefix[https://t.17track.net/en#nums=]]}}}
>Track All</a>
</$set>
note: you don't actually need to use a variable at all. Just combine the
two filters, like this:
<a href=
{{{[tag[IncomingItem]!has[date_received]has[tracking_number]get[tracking_number]join[,]addprefix[https://t.17track.net/en#nums=]]}}}
>Track All</a>
also, you might want to add target="_blank" to your link, so that it opens
in a separate tab/window.
<a target="_blank" href=
{{{[tag[IncomingItem]!has[date_received]has[tracking_number]get[tracking_number]join[,]addprefix[https://t.17track.net/en#nums=]]}}}
>Track All</a>
enjoy,
-e
--
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 [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/tiddlywiki/7629662e-5346-4b05-8fff-605e7131d29bo%40googlegroups.com.