Can't add "file.zip" as a download.

Discussion in 'Web Design and Development' started by HarryPot, Oct 27, 2011.

  1. HarryPot macrumors 6502a

    Joined:
    Sep 5, 2009
    #1
    For some reason, when I put a download link to a .zip file an error occurs in Safari.

    I have the next:

    <a href="archive.zip">archive</a>

    And when trying to save it from Safari, the next error appears:

    Can't save the file Donwload-1.(null)

    Any ideas?
     
  2. DewGuy1999 macrumors 68040

    DewGuy1999

    Joined:
    Jan 25, 2009
    #2
    Is the linked zip file in the same directory as the source web page?
     
  3. HarryPot thread starter macrumors 6502a

    Joined:
    Sep 5, 2009
    #3
    Yes, the ".zip" file is in the same folder as the ".html" file.

    Could it have something to do with the fact I used the Finder "compress" option?

    ----------

    I think that it was a problem with my Mac. Now it works correctly.

    Thanks anyway.:)
     
  4. DewGuy1999 macrumors 68040

    DewGuy1999

    Joined:
    Jan 25, 2009
    #4
    I don't think that having zipped it with Finder has anything to do with it. I fiddled around with it a bit last night after I posted my question (using a test file) and I think it's specific to Safari and the file being on your hard disk. When using Safari the link wouldn't do anything (no error message though), but Firefox 7.0.1 didn't have any problem with the same setup and proceeded to download. When the same html file was linked to the same zipped file, but on the net (instead of on my hard drive) Safari downloaded it. Maybe it's intentional to prevent some kind of malicious behavior from being executed from within Safari against your computer.
     
  5. HarryPot thread starter macrumors 6502a

    Joined:
    Sep 5, 2009
    #5
    Makes sense. I tried again to download the file locally, and it doesn't work. It do works in the online server tho.

    And as you said, it also works in Firefox when offline. Thanks again.:)
     

Share This Page