Results 1 to 10 of 10
  1. #1
    Join Date
    Oct 2005
    Posts
    78
    Plugin Contributions
    0

    Default How to upload downloadable files?

    I am a bit embassed to ask this question but i am lost even after trying to research it out. All i want to know is if i upload a file to my server, for example bradislost.mp3 how do i make it downloadable when i click on it, instead of run it. So it brings up the box Open or Save. and i can click save. I am so lost it if frustating.

    Thanks,

    Brad

  2. #2
    Join Date
    Apr 2004
    Location
    UK
    Posts
    5,821
    Plugin Contributions
    2

    Default Re: How to upload downloadable files?

    Add to a zip file, make zip file downloadable

  3. #3
    Join Date
    Jan 2005
    Location
    Lake Havasu, AZ
    Posts
    1,149
    Plugin Contributions
    0

    Default Re: How to upload downloadable files?

    Brad - this is unavoidable if you are going to use MP3 files. The settings which control whether the MP3 comes up as a download or immediately plays are in the player of choice / internet options on the browser you are using.

    Since you cannot control this on all visitor computers, you would either want to offer the download as a zip or rar file OR put a statement in the download page / checkout success that the client will have to right-click "File Save As" in order to download in some cases.

    I designed a cart for a local record company and we had the same exact problem, ended up going with zip files.
    When the world gets in my face I say Have A Nice Day.
    * I DO Think and I HAVE BEEN Zenned - therefore, I AM * I donate - do you?
    Custom Templates and Zen Services CRS Designs, Inc.

  4. #4
    Join Date
    Oct 2005
    Posts
    78
    Plugin Contributions
    0

    Default Re: How to upload downloadable files?

    That can't be true because some websites allow you to download MP3 plus your phone dowloads it as a mp3. So there must be some way of doing it.

  5. #5
    Join Date
    Feb 2006
    Location
    Chicago
    Posts
    1,162
    Plugin Contributions
    0

    Default Re: How to upload downloadable files?

    Quote Originally Posted by bradlawson
    That can't be true because some websites allow you to download MP3 plus your phone dowloads it as a mp3. So there must be some way of doing it.
    Phones are fine, but can you tell me any site which will let me download mp3
    Thanks

  6. #6
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: How to upload downloadable files?

    Quote Originally Posted by bradlawson
    how do i make it downloadable when i click on it, instead of run it. So it brings up the box Open or Save. and i can click save.
    It might be possible with some javascript which forces delivery to require confirmation of method chosen.... just a thought ... haven't tried it.
    Would be interesting to look at a site that already works as you desire, and see the technique used ... for inspiration ;)
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  7. #7

    Default Re: How to upload downloadable files?

    There are two options for this.

    One is PHP and requires some knowledge of programming.

    The other is a simple edit of the .htaccess file in the folder where you are storing these files. (This assumes you're hosting on an Apache server.)

    Put these lines in the file:

    AddType application/octet-stream mp3

    (or)

    <Files *.mp3>
    ForceType application/octet-stream
    Header set Content-Disposition attachment
    </Files>

    Then the files will be forced to download instead of open in the music player.

    Regards,

    Ale Elatey
    Last edited by all80; 11 Jul 2006 at 04:36 AM.

  8. #8
    Join Date
    Oct 2005
    Posts
    78
    Plugin Contributions
    0

    Default Re: How to upload downloadable files?

    all80 thanks for the suggestion but i couldn't get it to work. My site is running on a linx server with apache 1.3.36 (Unix). I am not fimlar at all with apache. But i created a .htaccess file with the code

    <Files *.mp3>
    ForceType application/octet-stream
    Header set Content-Disposition attachment
    </Files>

    then i saved it in the directory with the mp3 and i didn't work. It just played the mp3 like usually. Is there something i am doing wrong?


    Thanks,

    Brad

  9. #9

    Default Re: How to upload downloadable files?

    Try the other option.

    Are you using a Unix server? Do you have control over setting file types? Your ISP may not allow re-writing the file types.

    If you don't know the answer to these questions then you'll have to offer the right click 'save as...' option as mentioned before.

    There will not be a full solution to this as any settings you use can be over-ridden by the users settings.

    Ale.

  10. #10

    Default Re: How to upload downloadable files?

    Just an FYI -

    I've just tested the options (.htaccess and php) in both IE and Firefox.

    With Firefox, there is no way to force a download as Firefox will over-ride and give the option of open or save (depending on settings).

    IE will also depend on the user settings. If the user has not changed ANY default settings then it should work. But if the user has set the file type for the mp3 player (extremely likely if they've ever played an mp3) then the mp3 will automatically play instead of download unless they right click and select 'save as...'

 

 

Similar Threads

  1. Downloadable Free Pdf files--How?
    By FukienMan in forum Setting Up Categories, Products, Attributes
    Replies: 6
    Last Post: 5 Nov 2011, 04:46 AM
  2. How To upload files for Downloadable products?
    By fe1lho in forum Basic Configuration
    Replies: 2
    Last Post: 14 Jun 2010, 10:53 AM
  3. How do I upload my ebook as a downloadable product?
    By frank67 in forum Setting Up Categories, Products, Attributes
    Replies: 2
    Last Post: 19 Oct 2009, 12:59 AM
  4. Replies: 0
    Last Post: 29 Sep 2009, 06:49 AM
  5. Where to upload my files for downloadable products?
    By HOVERING in forum General Questions
    Replies: 1
    Last Post: 14 Mar 2009, 03:46 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR