Use tokens inside of tokens (nested tokens)

Use tokens inside of tokens (nested tokens)

It would be nice to be able to use a token inside of another token.  For example- I may have a token called "event description" that would include the event name, date, time, URL, etc.  that I have already tokenized.  By using these tokens inside of this other token, it would allow me to do less overall updating when cloning the campaign. 

4 Comments
Dan_Stevens_
Level 10 - Champion Alumni

Existing idea:

In fact, here's the grandaddy of ideas around tokens:

SanfordWhiteman
Level 10 - Community Moderator

Dupe like Dan said... also note that Velocity (email script) tokens can in fact be nested, or more precisely, share internal variables.

So in your example:

----BEGIN TOKEN 1----

#set( $eventDescription = {

"name" : "blah",

"date": "2017-02-15"

} )

----END TOKEN 1----

----BEGIN TOKEN 2----

${eventDescription.name} ## references the data from the other token

----END TOKEN 2----

Some mind-blowing stuff can be done with this.

Anonymous
Not applicable

Thanks!  That is good to know!

kh-lschutte
Community Manager
Status changed to: Open Ideas