Skip to content

Rhaptos Software Development

Personal tools
You are here: Home » Documentation » Author/Reader Communication » CNX@CNX.ORG FAQ » How do I add a downloadable file to my module?

How do I add a downloadable file to my module?

Document Actions
It is fairly easy to include the files for download. Let's say you want to include an MP3 audio file, myfile.mp3, in your module. First, go to the "Files" tab for the module, select "File" from the third drop-down box, and then click the "Create new item" button next to that box. This will allow you to browse on your local machine and select myfile.mp3 from where you've stored it. Then click the "Save" button, and myfile.mp3 will be attached to your module.

Then, you have to give your module readers some way to access it. I would recommend that you use the CNXML <link> tag to do so. At the point in your module where you'd like to direct the reader to download the file, you can include something like:

You can download <link src="myfile.mp3 ">the audio file</link>.

When the user clicks on the "clicking here" link, they will either be able to download and save the file or choose to let their browser launch their local audio player and play the file.
Created by rwagner
Last modified 2008-07-10 17:47