# Download link for mp4 and other files



## icode (Dec 31, 2007)

I recently did a page with a download link to an mp4 file however when you click on the link to download the file it start to download in the same browser window I changed the target link to open in new windows but all that does is make the short movie clip load in the other window is there a script I can use to make the file download when the link is clicked on instead of starting to open in new browser window. Right now the work around this is to right click on the link and then select "save target as" which is a bit less straight forward so I perfer if you could simply click the download link and the short movie clip is downloaded onto the visitors pc.
Any ideas on how I can get this done?


----------



## ushigley (Apr 2, 2007)

You are able to use PHP to trigger a file download, otherwise I'm not sure if something like that just depends on the browser. If you are planning on putting this page for view to the public, just know that this is an encoded music file type an other people will probably not be able to listen to it.


----------



## carsey (Aug 19, 2006)

There are download scripts you can use that allow you to do this.
Have a look through these:
http://www.hotscripts.com/PHP/Scripts_and_Programs/File_Manipulation/Download_Systems/index.html


----------

