Reputation: 48798
Is there a way to only allow a user to edit a link's destination, and not the link itself, using MailChimp's template language? There doesn't seem to be anything about this specific situation in their documentation.
For example:
<a href="link.html" target="_blank">
<img src="button.gif" alt="Button Name" />
</a>
So I want to allow the user to ONLY edit "link.html
" to point somewhere else, as the link button never changes.
Unfortunately, to make matters more complicated, there's an unknown number of links in the template (thanks to the use of mc:repeatable
), so the solution cannot be hard-coded to a specific link.
Is this possible?
Upvotes: 19
Views: 12002
Reputation: 11
I have come to the same conclusion as many here, there is no easy way to do this in MailChimp, or Campaign Monitor.
In MailChimp, the only current way is to use their boilerplate templates that have "Content Blocks," which make editing very simple - you just can't custom code your own template. What we need is the ability to code custom templates with 'Content Blocks,' which is not currently available in MailChimp.
Read about Content Blocks Here:
http://kb.mailchimp.com/campaigns/content-blocks/about-content-blocks
Upvotes: 1
Reputation: 559
I ran into exactly the same issue today. It seems the individual href attribute cannot currently be made dynamic using merge tags in Mailchimp.
The best workaround I've found is to create an editable field (span) within the repeatable section that contains the link and button image.
<tr mc:repeatable>
<td width="600px">
<span mc:edit="offer_link">
<a href="http://www.mywebsite.com" target="_blank">
<img src="http://www.mywebsite.com/images/button.png" width="100" height="30" alt="view offer button">
</a>
</span>
</td>
</tr>
When the sender creates the email from the template, they can click the '<>' icon in the editor to edit the html for the link. They'll need some very basic HTML knowledge but it'll do the trick.
Upvotes: 8
Reputation: 5920
In your MailChimp template, instead of using <a href="link.html" target="_blank">
, use a Merge Tag instead. So for example:
<a href="*|CUSTOM_URL|*" target="_blank">
Follow these steps to complete the set up:
Lists
> Create Forms
and add a new input field.Field Settings
.Custom Url
.Field Tag
to CUSTOM_URLRequired Field
.Field Visibility
to Hidden.Default Merge Tag Value
to http://www.example.com/new-link.html
(in other words, this is where the SENDER would input the absolute URL that you want your link.html
changed to before sending each Campaign.When the Campaign is sent, it will automatically fill in this default link (new-link.html
) for the href
attribute on the link without the SENDER actually modifying the campaign.
Just be sure that no one actually enters a value into this field when adding subscribers or it will override the default value set by the SENDER.
Upvotes: 6