Can T Download Zip Files

When I right-click on links for attached mbst-grab-results.zip in replies and choose Save Link As. I download a ~ 55 KB file named. I can't open zip. Files anymore I've recently downloaded a file which came in a zip. Format and should be containing an image. Usually when I download something of this file type, I am able to click on the file and select 'extract files', but with a few files I've downloaded recently, this option doesn't appear.

In HTML, how do you link to a file that the browser can only download, not view? For instance, say I have a zip file, my-program.zip. I want visitors to my website to be able to download that file when they click a link. The link would look like this: download my program. On my webserver, the HTML file and the zip file are in the same directory, so the relative path of the zip file is simply its filename.

But if I just link to the file with an <a href='my-program.zip'> tag, the browser wouldn’t recognize the link, right? Because browsers can’t open zip files. So what is the proper way to link to it?

Rory O'Kane

Can't Download Zip Files From Fire Stick Jailbroken

Rory O'Kane
19.4k8 gold badges67 silver badges110 bronze badges

1 Answer

Actually, your example is the proper way to link to the file:

You can never tell for sure that a browser can’t view a file. You just link to it; it’s up to the browser to do what they think best with it – display it, download it, or do something else. Don’t worry; browsers will generally do the right thing.

This follows the principle of the web that you don’t know what the browser will do with the files and pages you send it. You mentioned a ZIP file, but think of PDF files. They are like a ZIP file: they are not HTML, they are not made for a browser, and the browser might download it. But there are plugins such as Adobe PDF Reader and Schubert’s PDF Browser Plugin that show the contents of the PDF file right in the browser. Similarly, hypothetically, there might be a ZIP file viewer for the browser – it might show the user the contents of the ZIP file in the browser and let the user decide where to extract those contents.

Most browsers don’t have the hypothetical ZIP file viewer described, so the file will just download, like you wanted. But that doesn’t really matter; just write your link and everything will be okay.

Can't Download Zip Files

The browser could do things other than viewing the file or downloading the file right away. It could also ask the user if they want to download the file. Or it could start downloading the file, detect a virus in it, and delete it right away. The point is, it’s up to the browser what it does with the file.

Note that this policy goes the other way. Your HTML pages look to the browser just like files look – they are both “resources”. “Resource” is the “R” in “URL”. When you visit an HTML page by visiting a URL, the browser thinks “this is an HTML resource. What should I do with this? Oh, I can display it in the main window – I’ll do that.” This is the same process as downloading a ZIP file after clicking a link to its URL, where it thinks “this is a ZIP resource. What should I do with this? I can’t display it – I guess I’ll start downloading it and open the downloads window so the user can see what happened.” Most browsers even let you download the HTML of a page just like a file, if you ask it to.

If you have multiple formats of your file, and want to let the browser choose the best one it can view, then you could set up a system using the HTTP Accept header. For instance, if you had both a ZIP and a RAR version of my-program, then you could make it so you link to just my-program and the browser chooses the version it likes best. But the setup for that can be complicated, and that kind of system isn’t usually necessary for just a file download. The Accept header is usually used to get the correct version of something that the browser is meant to view – for instance, the browser might choose an MP4 video file over a WMV video file because it doesn’t have any codec that can play embedded WMV videos.

If you want to force the browser to download a file even though the browser can probably view it on its own, see this question.

Community
Rory O'KaneRory O'Kane
19.4k8 gold badges67 silver badges110 bronze badges

Not the answer you're looking for? Browse other questions tagged htmlhyperlinkdownload or ask your own question.

Related question: Native alternative to wget in Windows PowerShell?

The question might sound stupid, but this is often a major issue for me. Consider the following scenario:

The customer has a fresh Windows Server 2008 based system into which I can connect via RDP. The only available browser is Internet Explorer with the default security guidelines that don't allow you to do anything.

I want to avoid maintaining the 'trusted sites' list at all costs!

So this is what doesn't work for me:

  1. Download Chrome (requires JavaScript, which is not available)
  2. Download Firefox (the download location is not trusted, adding it to the trusted sites doesn't help either, because the CDN directs to a different site the next time)
  3. Connecting to a network share of the server (won't let me authenticate, might be another issue).
  4. Sending me the file per mail doesn't work either, because it exceeds the file size limit for messages.

Where is the wget on Windows Server?

Update regarding RDP-based approaches
I assume that some of the proposed solutions did not work for me because the server I was working on when writing the question was accessed through an RDP gateway (from the company's Remote Web Access site).
Additionally, I tried confirming (RDP-related) solutions against other servers I was working on at the time (which were accessed without a gateway).

For example, I believe clipboard sharing is not available when connecting through a gateway. But I have yet to confirm this.

Community
Der HochstaplerDer Hochstapler
69.2k50 gold badges236 silver badges288 bronze badges

6 Answers

sinni800sinni800
2,7703 gold badges18 silver badges36 bronze badges

Internet Explorer with the default security guidelines

Why not just turn them off for administrators. Click on the Configure IE ESC link in Server Manager under the Security Information section and change it.

It's three clicks and if memory serves, doesn't even require to close and reopen IE.

Or is the 'default security guidelines' also company policy and though you may be able to technically do so, you'd be violating policies... in which case, I don't see how doing the other options wouldn't be just as insecure if not more so. (Security by obscurity is not security).

As for obtaining Firefox (for example), use the command line FTP and download it.

Der Hochstapler
69.2k50 gold badges236 silver badges288 bronze badges
Multiverse ITMultiverse IT

One way to go is to use PowerShell with WebClient:

Der HochstaplerDer Hochstapler

Can't Download Zip Files Chrome

69.2k50 gold badges236 silver badges288 bronze badges

RDP allows you to redirect drives, sounds, printers and even serial ports from the client to the server, use that to transfer installation files to the server.

You can find this as an option in the 'Remote Desktop Connection' tool (mstsc):

IE has no use in this case and you certainly don't want to install flash or enable js/pdf/java on your server just to download a few files.

Some tools you could use to get rid of the official RDP client:

I use Remmina on a day to day basis to administer my windows servers from my linux desktop.

There is a fork of the mRemote source code, that project is open source free software (GPL) and is named mRemoteNG.

It supports the following protocols: RDP, VNC, ICA (Citrix), SSH, Telnet, HTTP/HTTPS, rlogin and Raw socket connections

Can T Download Zip Files
ShadokShadok

If you're using Windows 7 (Pro for sure works) and Windows server 2008, you can just directly copy and paste the .exe files between them. This is without changing anything anywhere. I'm not sure if there is a size limit, I've done up to about 100MB in file size without problems.

On your local computer copy to clipboard firefox.exe

(or whatever) and on the server simply paste.

Firefox

I've tested this with, win2008 to win7pro, win7pro to win2008, win7pro to win7pro. It might work with win7home to win7pro or win2008.

Viper_SbViper_Sb
8812 gold badges9 silver badges12 bronze badges
  • Download TeamViewer at TeamViewer.com
  • Install on your Win 7 or any Windows Platform
  • DownLoad TeamViewer to your Win 2008 Server, but don't Install, choose 'Run' instead, this will put it into the 'Non-Commercial/FREE' mode, otherwise it will recognize that you are installing on a server and only allow the Commercial/FEE version to be installed.
  • Then simply connect the two computers via a TeamViewer Remote Control or File Transfer connection – your choice.

    Remote Control allows you to remotely control another Windows machine and still offers the file Transfer via the toolbar at the top of the screen, or you can start directly with a 'File Transfer' connection by choosing the radio box before connecting.

  • Once in the File Transfer mode, a GUI box similar to a FTP box will appear, allowing you to select files in bulk or individually to transfer in between the two computers.

Unable To Download Zip Files

slhck
167k48 gold badges464 silver badges481 bronze badges
Tech SupportTech Support

Not the answer you're looking for? Browse other questions tagged downloadwindows-server-2008windows-server-2008-r2 or ask your own question.