click image to download??

This is a discussion on "click image to download??" within the Web Page Design section. This forum, and the thread "click image to download?? are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Dec 12th, 2006, 15:02
Junior Member
Join Date: Nov 2006
Location: milton keynes
Age: 28
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
click image to download??

Not sure if this question really belongs in this forum or not but hey it involves an image. Basically I want people to be able to click on an image & instantly download an mp3. Im using dreamweaver 8. I know how to link the image to the mp3 but that way people have to right click & "save target as" to download. I want people to be able to just click on the image & start the download but I dont know how to set this up. Can any help me out with this???
Reply With Quote

  #2 (permalink)  
Old Dec 12th, 2006, 17:59
Reputable Member
Join Date: Dec 2005
Location: Bristol
Posts: 268
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

Moved to HTML forum.

Last edited by Daniel; Jan 4th, 2007 at 14:42.
Reply With Quote
  #3 (permalink)  
Old Dec 12th, 2006, 20:29
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

There is no way to get around that. Browsers choose how to handle downloads individually. It would be a huge security hole in Windows if downloads started without confirmation.
Reply With Quote
  #4 (permalink)  
Old Dec 12th, 2006, 21:54
Junior Member
Join Date: Nov 2006
Location: milton keynes
Age: 28
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

I dont want the download to start automatically i just want to have a button/image/icon that says "download" and if you click on it it starts the download. Sort of like on this site http://www.download.com/McAfee-SiteA...-10508464.html. Here if you click where it says download now the download starts. I want to set something like that up.
Reply With Quote
  #5 (permalink)  
Old Dec 13th, 2006, 00:22
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

<a href="file-to-be-downloaded.zip">Download File</a>
Reply With Quote
  #6 (permalink)  
Old Dec 13th, 2006, 00:24
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

Or do you want a file to just download instead of it being displayed (or played) in the browser itself?
Reply With Quote
  #7 (permalink)  
Old Dec 15th, 2006, 12:39
Junior Member
Join Date: Nov 2006
Location: milton keynes
Age: 28
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

Thanks. I change the code a little to incoperate the image i want to use. <a href="insert file to be downloaded"><img src="Insert image" /></a>

But with that code if a user was to click on the image to download the file (which is an mp3) it plays it rather than starting the download. the user could start the download by right clicking & chosing "save target as" but I would like to set it up so that when the image is clicked a windows dialog box will pop up starting the download & asking where they would like to save the file.
Reply With Quote
  #8 (permalink)  
Old Dec 15th, 2006, 23:09
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

I think you can use PHP to force the download. You'd have to set up a lot of security measures, though. The script is rather dangerous.
Reply With Quote
  #9 (permalink)  
Old Jan 3rd, 2007, 02:20
New Member
Join Date: Dec 2006
Location: San Angelo, Texas
Age: 56
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

Make the the mp3 file into a zip file or even a self executable zip, that way it will download instead of play. I had the same problem with some pps files on my website and making them into a self executing zip file fixed it, if you need help doing that just holler.
Reply With Quote
  #10 (permalink)  
Old Jan 3rd, 2007, 19:25
Ryan Fait's Avatar
SuperMember

SuperMember
Join Date: May 2006
Location: Las Vegas
Posts: 3,786
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

Here are some examples of the PHP force download:

http://www.google.com/search?q=PHP%20Force%20Download
Reply With Quote
  #11 (permalink)  
Old Jan 3rd, 2007, 23:34
Junior Member
Join Date: Nov 2006
Location: milton keynes
Age: 28
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Re: click image to download??

Thanks for help guys! its much appreciated! Thank you. So how do I go about making a self executable zip? I know how to zip a file and I'll try that when I get a chance but whats a self executable zip? that sounds cool.
Reply With Quote
  #12 (permalink)  
Old Jan 4th, 2007, 14:41
moojoo's Avatar
Moderator
Join Date: Aug 2005
Location: Texas
Age: 31
Posts: 1,996
Blog Entries: 1
Thanks: 0
Thanked 32 Times in 32 Posts
Re: click image to download??

It's a zip that opens itself silly =P
__________________
I hate IE 6. Just sayin....
http://www.mevans76.com
Last Blog Entry: Apps every Mac based web dev should consider (Jul 10th, 2008)
Reply With Quote
Reply

Tags
download, image, mp3

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Download button - to download a PDF file attila001122 Web Page Design 4 Aug 15th, 2008 11:44
Moving TD on click of an image akshitshah JavaScript Forum 2 Sep 24th, 2007 05:31
Flash image link with rollover and sound on click markmod1 Flash & Multimedia Forum 5 Jun 17th, 2007 19:53
designing a site for batch image upload/download & viewing zephicus Starting Out 1 Mar 22nd, 2007 10:27
Download djforemanuk Introduce Yourself 1 Oct 2nd, 2005 15:50


All times are GMT. The time now is 10:31.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43