🔥New premium products for designers. Check them

Webflow js
May 14, 2021

Use Webflow CMS for managing custom url of attachament

Make more trust in your clients and customers using custom URLs for downloading of attachment sources like docs, pdfs using webflow cms.

For many of my clients is necessary to share their files from the direct url based on their direct name instead of some other naming like upload.webflow etc. It was crucial in some cases to allow sharing the custom url for the donwloading of the files. So I have made a small workaround using Webflow CMS for customizing the URLs. So you will use nameurl.com/docs/file instead of uploads-ssl.webflow.com/filename.

Here is the Webflow CMS attachement workaround

1. Set-up CMS collection for pasting the docs

Name the collection as you need like: "docs, assets, documents etc.". Add only required field: attachaments for uploading your files.

2.Put small custom code into embed code in your collection page

The custom code will start downloading of your attachament automatically when page is load.


<div onload="download()"></div> <a id="dl" style="display: none" href="add your attachament field from collection here" download>Download</a> <script> (function download() { document.getElementById('dl').click(); })() </script>

3. Design your CMS collection page as "Thanks for downloading page"

This step might be crucial for your customers as the downloading starts automatically. Let them knows what has happened on the page. Add the button to move them back on your homepage or list of your docs.

4.Add files to your docs collection

Last part is to add all unnecessary attachaments to your collection :-)

Hope it will help you! Leave me a feedback or follow me on Twitter to stay updated!

Wish you a creative day,
P.

Let's talk about the topic

Comments

I picked some other writings

Related topics

Love the article? Subscribe to stay updated

You will subscribe to our newsletter. We promise you no spam, only notifications about resources, products, updates, and freebies. You can always unsubscribe whenever you want.

Tap to close