Skip to main content
Grégoire_Miche2
New Participant
June 14, 2016
New

Email editor 2.0: variables in the text version

  • June 14, 2016
  • 12 replies
  • 13541 views

One limitation of the new text editor; variables are only supported in the HTML version, not is the text one.

So let's say you want to use a variable for the title of the email:

<p style="font-weight: bold; font-size:16px;">${EmailTitle}</p>

This paragraph would just not show up in the text version, meaning that the title you have set in the variable will not shown up in the text version.

-Greg

12 replies

New Participant
February 6, 2020
No text available
Ulf_Deeg
New Participant
July 27, 2018

I do the following workaround

  1. embed variables as follows:   a href="${CTA-url}"
  2. use tokens like {{my.CTA url}} and to use inside the variable field
  3. use token like {{my.CTA text}} for the button text
  4. add a HTML invisible mktoText section inside the same module that contains the CTA
    <div class="mktoText" mktoname="CTA Text Only" id="cta-textonly" style="display: none; max-height: 0px; font-size: 0px; overflow: hidden; mso-hide: all">
    {{my.CTA text}} <[[{{my.CTA url}}]]>
    </div>
  5. the Text Only version will pull in {{my.CTA text}} <[[{{my.CTA url}}]]> as a separate line

Our Email Programs have tokens for every CTA module (of which you will need clones anyhow when using Variables). CTA1 text, CTA1 url, CTA2 text, CTA2 url and so on.....

If you use a Master Email Program that gets cloned, your fine. We need this anyhow due to several languages we market to.

SanfordWhiteman
Level 10
April 12, 2018
Dan_Stevens_
New Participant
April 12, 2018

Sandy, we're using variables for all of our call-to-action buttons, for example:

<meta mktoModuleScope="true" class="mktoString" id="Two-col-CTA-url" mktoName="CTA URL" default="#">

....

a href="${Two-col-CTA-url}

And aren't experiencing the issues that you mention in your blog post (or the error that Jared received when trying to save his template).  And your fix isn't included anywhere in our template.  Wonder why this works for some and not for others?

BTW, is it me or is the Advanced editor not available here in the Ideas section - so that we can format/highlight code properly in our comments?

Grégoire_Miche2
New Participant
April 12, 2018

Hi Dan

It's not you The editor does not provide code highlighting on ideas.

-Greg

Matt_Ondo
New Participant
April 2, 2018

@Justin Cooperman​, string variables are something we rely on heavily for CTA buttons since buttons are such an unstable element in email development. I totally understand this may be difficult to implement, could I ask for this to be added to the Email Editor 2.0 Overview nor Email Template Syntax documentation? Maybe one of those "Caution" callouts on the docs that states: "Only content within mktoText and mktoEditable regions will be translated into the Text-Only Version."

SanfordWhiteman
Level 10
April 2, 2018

Tokens work fine as well.

It's specifically a thing with variables (which didn't exist -- in Emails -- before 2.0)

Dan_Stevens_
New Participant
February 9, 2018

Now that we have officially deployed our new "all-in-one" template in Marketo, I'm now finally realizing what an issue this is.  The template uses variables extensively for things like editable hero banners, call-to-action buttons and URLs.  For example:

Produces a text version that will require manually editing every time:

Would really like to see Marketo address this and add it to the roadmap of "things that just don't work like they should".

Grégoire_Miche2
New Participant
February 9, 2018

Hi Dan

Welcome to the fan club

-Greg

November 20, 2017

@Justin Cooperman​

Has there been any change in stance on this? Still not on the road map? Seems as though other users have a seemingly reasonable path forward re this challenge?

Justin_Cooperm2
New Participant
November 21, 2017

It's still not on the roadmap, only because we don't have any changes planned to the email editor (due to the team's 100% focus on the new UX). Once we get parts of that rolled out, we'll be able to get back into the editors and make some of these improvements.

Justin

July 20, 2017

Hi @Justin Cooperman​ - any update on this?  Is it on the roadmap?

Justin_Cooperm2
New Participant
July 25, 2017

This is not currently on the roadmap.

In Email 1.0, customers would edit the HTML and TEXT versions of each individual rich-text region, which would build out the content seen in the TEXT version of the email. This is no different in Email 2.0, other than we auto-copy all of the contents of each individual rich-text section over to the TEXT side for easier editing. If there are regions of your email outside of rich-text editable elements that you want copied over to TEXT (this is also commonly the case with content statically defined in the template or tokens outside of editable elements), then you must do it manually.

We understand that it would be convenient at times to have certain variables copy over, but there aren't currently plans to implement this. I do think this would be extremely tricky to build correctly. How would we know what "variables" to copy over to Text? Also, where would we insert the variable contents into the text? You may say what ever is "above" the other...what if things are side-by-side? Should all variables copy over or only certain ones (would you really want a "list" variable copying over the font-family you selected for a piece of text?)? Should you be able to "tag" certain ones?

Anyway, lots of questions about how this would work? I am 100% open to hearing suggestions for how we could build something straightforward that would make life easier here. Please keep voting + post ideas of how you think this would work best! Also available, as always, via email jcooperman@marketo.com

Justin

New Participant
July 26, 2017

Hi Justin,

I understand this is complicated. If it is a question of what to copy over, would it be possible to add an attribute to string variables similar to mktoModuleScope or mktoAddByDefault?

This way if you are using string variables for Titles, Text, Labels and Links you would define those variables to write the value to the text version by adding e.g. "mktoAddToTxt=True".

I don't know what kind of backend changes need to be made for this but since you asked for ideas, that's the best applicable solution I see without having to make a ton of changes

/Erik

February 22, 2017

Bumping up again.... This is a major issue, Marketo. I thought variables was the whole point of 2.0. Please work on this ASAP.

SanfordWhiteman
Level 10
February 22, 2017

It's craziness, eh?  This is why I sigh when a client has upgraded to 2.0 without asking first...

February 6, 2017

Bump, going on a few months now. Is there a workaround to this?

November 29, 2016

Is there any update on when this will be fixed?