link to download a file

All WYSIWYG Web Builder support issues that are not covered in the forums below.
Forum rules
IMPORTANT NOTE!!

DO YOU HAVE A QUESTION OR PROBLEM AND WANT QUICK HELP?
THEN PLEASE SHARE A "DEMO" PROJECT.



PLEASE READ THE FORUM RULES BEFORE YOU POST:
http://www.wysiwygwebbuilder.com/forum/viewtopic.php?f=12&t=1901

MUST READ:
http://www.wysiwygwebbuilder.com/getting_started.html
WYSIWYG Web Builder FAQ
Post Reply
ddaugherty
 
 
Posts: 26
Joined: Thu Sep 05, 2013 4:58 pm
Location: McKinney, TX
Contact:

link to download a file

Post by ddaugherty »

How can I create a link to allow a visitor to download a file? I've tried setting "Link to" as a "External Web Address" and "File". Both open and display the file when the link is selected. I want it to just download the file, not open it. Thanks.
User avatar
Psycho
 
 
Posts: 16
Joined: Wed Oct 18, 2017 1:24 pm

Re: link to download a file

Post by Psycho »

Have you tried the download attribute ? it must be set within the href reference attribute

Not sure if all browsers support it but worth a shot

<a href="image.jpg" download>

Simply change the file name and file attribute above for the file you want folk to download
I have enough money to last me the rest of my life - Providing I die by next Tuesday
User avatar
BaconFries
 
 
Posts: 5364
Joined: Thu Aug 16, 2007 7:32 pm

Re: link to download a file

Post by BaconFries »

See the following reading from "link to a file" Links
You can then add a simple text beside the link telling the readers that they need to right-click (Windows) or ctrl-click the (Apple) link in order to download it.
ddaugherty
 
 
Posts: 26
Joined: Thu Sep 05, 2013 4:58 pm
Location: McKinney, TX
Contact:

Re: link to download a file

Post by ddaugherty »

I ended up using this html code and it works:

<html>
<body>
<a href="docs/lifegroup.pdf" download>
<button>Class Directory</button>
</a>
</body>
</html>

The name of the file to download is lifegroup.pdf. Be sure to upload it to a sub folder on your server otherwise it won't download if you put it in the root directory.

The size of the button depends on how you size the HTML property box. Class Directory is the label on the button.
Below the button, I put text saying: Directory Download
Post Reply