I'm trying to pass a set a language variables into a respective set of Freeform generated inputs.
The obvious way to do it would be:
<div>
<label for="freeform_first_name">{exp:transcribe:replace name='contact_name'}</label>
{freeform:field:first_name attr:class="textinput" attr:placeholder="{exp:transcribe:replace name='contact_name'}"}
</div>
<div>
<label for="freeform_email">{exp:transcribe:replace name='contact_email'}</label>
{freeform:field:email attr:class="textinput" attr:placeholder="{exp:transcribe:replace name='contact_email'}"}
</div>
<div>
<label for="freeform_user_message">{exp:transcribe:replace name='contact_message'}</label>
{freeform:field:user_message attr:class="textarea" attr:placeholder="{exp:transcribe:replace name='contact_message'}"}
</div>
This results in the Label displaying the correct language variable as set by Transcribe. However the same language variables don't get parsed in the Freeform's attribute placeholder.
I've tried to stash:embed
the contact form and pass the variables from the originating template.
{stash:embed
name="snippets:contact-form"
process="end"
parse_depth="1"
stash:cntct_name="{exp:transcribe:replace name='contact_name'}"
stash:cntct_email="{exp:transcribe:replace name='contact_email'}"
stash:cntct_msg="{exp:transcribe:replace name='contact_message'}"}
And in the embed:
<div>
<label for="freeform_first_name">{stash:cntct_name}</label>
{freeform:field:first_name attr:class="textinput" attr:placeholder="{stash:cntct_name}"}
</div>
<div>
<label for="freeform_email">{stash:cntct_email}</label>
{freeform:field:email attr:class="textinput" attr:placeholder="{stash:cntct_email}"}
</div>
<div>
<label for="freeform_user_message">{stash:cntct_msg}</label>
{freeform:field:user_message attr:class="textarea" attr:placeholder="{stash:cntct_msg}"}
</div>
And still the FreeForm labels display the correct language variables. But the placeholder attributes are not getting generated, at all. Static text, though, does work.
Any ideas?