As part of a campaign, you might have an eBook or other content that you want your leads or contacts to be able to download. In previous blog posts, we have discussed options for gated content through auto-responder emails and on-click downloads with a timed redirect. You can also give customers the option to either view the content immediately or to email the content to themselves for later viewing.
The first scenario can be achieved by leveraging one of the additions that came with HTML5—an attribute called download, which can be added to the link tag <a>. Instead of redirecting within your browser, this tag generates a download of the link file automatically.* Additionally, you can achieve the second scenario with a mailto link, allowing customers to review the content at their convenience. If you’re interested in either strategy, keeping reading for how to implement.
*Note—this works in Chrome and Internet Explorer; Firefox opens a PDF but will not download it.
Step 1: Add Your Confirmation Text
For my example, I used the confirmation text from a form, but the same set up would apply for a survey or subscription management page as well if that’s what you use instead. One thing to note is that I’m not using the Post Redirect URL field in this set up; I’m using the confirmation text content area to place my text and link. You can certainly redirect to a page on your company’s site and implement the file download, but if you don’t have access to make such a page on your company’s site, the confirmation text is a good option.
The first step here is to add your content to the confirmation text’s content area. My sample content is shown below.
For the download link, you will need to highlight the text that should link to the file. Then, using the link manager, select the file that your link should point to.
In the link manager, you can select any of the files you already have uploaded or you can upload a new one.
Once you have added that link, click Insert Link and that will add your file’s link to the confirmation text. Then you can add the download functionality shown below.
Step 2: Add the Download Attribute
In the confirmation text window, there is a Source button. Clicking on that button allows you to toggle between the display version of the confirmation text window and the HTML version.
Since you already placed the file’s link in Step 1, you can click on that Source button and then locate the link for your file. If you use a file stored in the ClickDimensions file manager like I did, you should be able to find it by using the Ctrl+F keys and then typing “file” as your search term.
In the <a> tag for the file’s link, add the download attribute. (You can learn more about it here, but basically, it will override the default click function for a link and instead generate a download of the file that’s being linked to.) You can see that attribute in my sample code below.
Step 3: Add an Optional Mailto Link
If you want to let your customer send themselves a link to the document instead, you can set up a mailto link. On your confirmation text page, place another link (aside from your download link) for your customers to use to trigger the email. You can see my email link below.
To do this, you would add your link similar to how we added the file link in Step 1. Then you will go to the source view of the confirmation text window as we did in Step 2 when we altered the <a> tag for the download link.
However, this time, you are going to alter the link’s href attribute so it includes the mailto details. We talk more in-depth here on how to set up a mailto link, but you can see the example of how I set mine up below. You can include the file link by itself or also put a short message with it.
When that link is clicked, an email will be created similar to what is shown here.
Now you’re ready to implement one or both of these options and provide your customers with great downloadable content.