I'm having some difficulty downloading a zip file from a server URL using wget and curl. Neither worked the way they're supposed to work. For example, typing
Note: Website above is just an example and may not lead anywhere.
It should download the zip to the path where I ran the command. Instead, it downloads an empty file that's much smaller (same filename). Correct zip file is around 6MB, the downloaded file is 7KB. I also tried putting "quote marks" around the URL and also got the same result.
However, manually going to the website UI via browser, I'm able to download the correct zip file and unzip it.
Similarly, if I use curl command, it outputs a bunch of HTML text and says "This document has moved". For this, I used the following command.
-o /home outputs an empty file called
home. Using either wget or curl, how do I correctly download the entire zip file with all its contents, and not empty files with the same filename?