How to download files from command line in Windows like wget or curl
How can I download something from the web directly without Internet Explorer or Firefox opening Acrobat Reader/Quicktime/MS Word/whatever?
I'm using Windows, so a Windows version of Wget would do.
windows wget curl
|
show 5 more comments
How can I download something from the web directly without Internet Explorer or Firefox opening Acrobat Reader/Quicktime/MS Word/whatever?
I'm using Windows, so a Windows version of Wget would do.
windows wget curl
Just right clicking a file and hitting "Save Target As" or "Save Link As" or "Save As" (language varies depending on your browser) will work.
– BrainSlugs83
Oct 22 '12 at 5:53
21
The point of having a command is being able to write a batch file and run it (perhaps scheduled as a task) anytime you want. That's where the GUI falls short.
– Jbm
Nov 15 '12 at 14:11
3
How do you download with MS Word?
– Jaime Hablutzel
Aug 20 '14 at 12:16
5
@JaimeHablutzel Why would you ever want to download something via MS Word? MS Word is not a terminal.
– Braden Best
May 14 '15 at 20:53
1
@SDsolar Or just upvote/improve this answer below.
– Franklin Yu
Nov 13 '17 at 19:32
|
show 5 more comments
How can I download something from the web directly without Internet Explorer or Firefox opening Acrobat Reader/Quicktime/MS Word/whatever?
I'm using Windows, so a Windows version of Wget would do.
windows wget curl
How can I download something from the web directly without Internet Explorer or Firefox opening Acrobat Reader/Quicktime/MS Word/whatever?
I'm using Windows, so a Windows version of Wget would do.
windows wget curl
windows wget curl
edited Nov 15 '17 at 18:49
community wiki
8 revs, 5 users 67%
Peter Mortensen
Just right clicking a file and hitting "Save Target As" or "Save Link As" or "Save As" (language varies depending on your browser) will work.
– BrainSlugs83
Oct 22 '12 at 5:53
21
The point of having a command is being able to write a batch file and run it (perhaps scheduled as a task) anytime you want. That's where the GUI falls short.
– Jbm
Nov 15 '12 at 14:11
3
How do you download with MS Word?
– Jaime Hablutzel
Aug 20 '14 at 12:16
5
@JaimeHablutzel Why would you ever want to download something via MS Word? MS Word is not a terminal.
– Braden Best
May 14 '15 at 20:53
1
@SDsolar Or just upvote/improve this answer below.
– Franklin Yu
Nov 13 '17 at 19:32
|
show 5 more comments
Just right clicking a file and hitting "Save Target As" or "Save Link As" or "Save As" (language varies depending on your browser) will work.
– BrainSlugs83
Oct 22 '12 at 5:53
21
The point of having a command is being able to write a batch file and run it (perhaps scheduled as a task) anytime you want. That's where the GUI falls short.
– Jbm
Nov 15 '12 at 14:11
3
How do you download with MS Word?
– Jaime Hablutzel
Aug 20 '14 at 12:16
5
@JaimeHablutzel Why would you ever want to download something via MS Word? MS Word is not a terminal.
– Braden Best
May 14 '15 at 20:53
1
@SDsolar Or just upvote/improve this answer below.
– Franklin Yu
Nov 13 '17 at 19:32
Just right clicking a file and hitting "Save Target As" or "Save Link As" or "Save As" (language varies depending on your browser) will work.
– BrainSlugs83
Oct 22 '12 at 5:53
Just right clicking a file and hitting "Save Target As" or "Save Link As" or "Save As" (language varies depending on your browser) will work.
– BrainSlugs83
Oct 22 '12 at 5:53
21
21
The point of having a command is being able to write a batch file and run it (perhaps scheduled as a task) anytime you want. That's where the GUI falls short.
– Jbm
Nov 15 '12 at 14:11
The point of having a command is being able to write a batch file and run it (perhaps scheduled as a task) anytime you want. That's where the GUI falls short.
– Jbm
Nov 15 '12 at 14:11
3
3
How do you download with MS Word?
– Jaime Hablutzel
Aug 20 '14 at 12:16
How do you download with MS Word?
– Jaime Hablutzel
Aug 20 '14 at 12:16
5
5
@JaimeHablutzel Why would you ever want to download something via MS Word? MS Word is not a terminal.
– Braden Best
May 14 '15 at 20:53
@JaimeHablutzel Why would you ever want to download something via MS Word? MS Word is not a terminal.
– Braden Best
May 14 '15 at 20:53
1
1
@SDsolar Or just upvote/improve this answer below.
– Franklin Yu
Nov 13 '17 at 19:32
@SDsolar Or just upvote/improve this answer below.
– Franklin Yu
Nov 13 '17 at 19:32
|
show 5 more comments
18 Answers
18
active
oldest
votes
Wget for Windows should work.
From the Wget Wiki FAQ:
GNU Wget is a free network utility to retrieve files from the World
Wide Web using HTTP and FTP, the two most widely used Internet
protocols. It works non-interactively, thus enabling work in the
background, after having logged off.
From this section of FAQ, download links are suggested:
Windows Binaries
courtesy of Jernej Simončič: http://eternallybored.org/misc/wget/
from sourceforge: http://gnuwin32.sourceforge.net/packages/wget.htm
[...]
Link with courtesy of Jernej Simončič is used instead.
8
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
12
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
4
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
1
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
1
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
|
show 5 more comments
An alternative I discovered recently, using PowerShell:
$client = new-object System.Net.WebClient
$client.DownloadFile("http://www.xyz.net/file.txt","C:tmpfile.txt")
It works as well with GET queries.
If you need to specify credentials to download the file, add the following line in between:
$client.Credentials = Get-Credential
A standard windows credentials prompt will pop up. The credentials you enter there will be used to download the file. You only need to do this once for all the time you will be using the $client object.
82
You can also do it in one-line:(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
15
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
8
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
3
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
4
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
|
show 9 more comments
If you have PowerShell >= 3.0, you can use
Invoke-WebRequest
Invoke-WebRequest -OutFile index.html http://superuser.com
Or golfed
iwr -outf index.html http://superuser.com
Download a file via HTTP in Windows
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed toSystem.Net.WebClient
. However you can makeInvoke-WebRequest
work by adding-UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.
– Ela782
Jan 7 '16 at 12:22
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
add a comment |
Windows has its own command line download utility - BITSAdmin:
BITSAdmin is a command-line tool that you can use to create download
or upload jobs and monitor their progress.
EDIT: 26.01.15 -
Here's my overview of how a file can be downloaded on windows without external tools
And a complete bitsadmin example:
bitsadmin /transfer myDownloadJob /download /priority normal http://downloadsrv/10mb.zip c:10mb.zip
Edit : 15.05.2018 - turned out that's possible to download a file with certutil too:
certutil.exe -urlcache -split -f "https://download.sysinternals.com/files/PSTools.zip" pstools.zip
Certutil is not installed by default on XP/Win2003 but is avaialble on the newer windows versions.For XP/2003 you'll need the Admin Tool Pack for windows server 2003
7
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
2
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
12
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
1
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
4
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
|
show 3 more comments
Save the following text as wget.js
and simply call
cscript /nologo wget.js http://example.com
This is the code:
var WinHttpReq = new ActiveXObject("WinHttp.WinHttpRequest.5.1");
WinHttpReq.Open("GET", WScript.Arguments(0), /*async=*/false);
WinHttpReq.Send();
WScript.Echo(WinHttpReq.ResponseText);
/* To save a binary file use this code instead of previous line
BinStream = new ActiveXObject("ADODB.Stream");
BinStream.Type = 1;
BinStream.Open();
BinStream.Write(WinHttpReq.ResponseBody);
BinStream.SaveToFile("out.bin");
*/
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
1
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
4
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
add a comment |
I made a quick myGet.bat file which calls the PowerShell method described above.
@Echo OFF
SetLocal EnableDelayedExpansion
Set Var=%1
Set Var=!Var:http://=!
Set Var=!Var:/=,!
Set Var=!Var:%%20=?!
Set Var=!Var: =?!
Call :LOOP !var!
Echo.Downloading: %1 to %~p0!FN!
powershell.exe -Command (new-object System.Net.WebClient).DownloadFile('%1','%~p0!FN!')
GoTo :EOF
:LOOP
If "%1"=="" GoTo :EOF
Set FN=%1
Set FN=!FN:?= !
Shift
GoTo :LOOP
I borrowed some code from Parsing URL for filename with space.
1
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
add a comment |
There is a native cURL for Windows available here. There are many flavors available- with and without SSL support.
You don't need the extra baggage of Cygwin and the likes, just one small EXE file.
It is also important to know that there are both wget
and curl
aliases built into all modern versions of Windows Powershell. They are equivalent.
No extra files or downloads are required to obtain wget
functionality:
Using Curl In Powershell (The Sociable Geek)
Excerpt:
You can type in a cURL command like one that downloads a file from a
GitHub repository.
curl http://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json
and it will seem like it works but what it is actually doing is just
using cURL as an alias. In the above instance, what will happen is
that you will just get the headers instead of the file itself.
Aliases in PowerShell allow you to create shortcuts for longer commands so you don’t have to type them out all of the time.
If you type in the command Get-Alias, it will give you a list of all the Aliases that are used in PowerShell. As you can see, the curl command just calls the Invoke-WebRequest command. They are similar but not the same which is why the above request does not work for us.
To get this to work properly in PowerShell the easiest way is to use variables and the -OutFile
argument as shown here:
(file name cut off in image “https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json”)
This syntax will download the full contents of the target file azuredeploy.json
to the local file newfile.json
The primary advantage is that it is built into Powershell itself so this code will execute directly with no downloads or any other extra file creations are required to make it work on any modern version of Windows.
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
add a comment |
I was searching for the same, and since I had no privilege to install any of the above packages, I went for a small workaround (to download 30+files):
- I created a batch file
- Listed all the files
- Put
firefox.exe
at the beginning of each line - Went to the firefox directory in
Program Files
- Ran it.
add a comment |
If PowerShell is an option, that's the preferred route, since you (potentially) won't have to install anything extra:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt', 'C:tmpfile.tx??t')
Failing that, Wget for Windows, as others have pointed out is definitely the second best option. As posted in another answer it looks like you can download Wget all by itself, or you can grab it as a part of Cygwin or MSys.
If for some reason, you find yourself stuck in a time warp, using a machine that doesn't have PowerShell and you have zero access to a working web browser (that is, Internet Explorer is the only browser on the system, and its settings are corrupt), and your file is on an FTP site (as opposed to HTTP):
start->run "FTP", press "OK".
If memory serves it's been there since Windows 98, and I can confirm that it is still there in Windows 8 RTM (you might have to go into appwiz.cpl
and add/remove features to get it). This utility can both download and upload files to/from FTP sites on the web. It can also be used in scripts to automate either operation.
This tool being built-in has been a real life saver for me in the past, especially in the days of ftp.cdrom.com -- I downloaded Firefox that way once, on a completely broken machine that had only a dial-up Internet connection (back when sneakernet's maximum packet size was still 1.44 MB, and Firefox was still called "Netscape" /me does trollface).
A couple of tips: it's its own command processor, and it has its own syntax. Try typing "help". All FTP sites require a username and password; but if they allow "anonymous" users, the username is "anonymous" and the password is your email address (you can make one up if you don't want to be tracked, but usually there is some kind of logic to make sure it's a valid email address).
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
I'm not sure why you have two question marks in the destination fileC:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
add a comment |
And http://www.httrack.com/ has a nice GUI (and it's free), for mirroring sites. It also has a Linux version.
add a comment |
Cygwin has Wget (and many more utilities).
add a comment |
You can get WGet for Windows here. Alternatively you can right click on the download link of the item you want to download and choose Save As. This will download the file and not open it in the assigned application.
add a comment |
If you want a GUI, then try VisualWget, which is actually clean, and feature full. It is based on GNU Wget for its download engine.
EDIT: updated link.
1
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
add a comment |
You could also use the wget
packaged in PowerShell. ;^) To open, hit the Windows key and type "powershell" or Windows-R and type "powershell" and hit return.
No installation necessary.
One interesting difference from conventional wget
(more at that link): You can't simply use the greater-than to pipe to a file. wget
in PowerShell is just a convenience wrapper for Invoke-WebRequest
, and you need to use its syntax to write to a file.
wget https://superuser.com/questions/25538 -OutFile rubySlippers.html
1
-OutFile
did the job!
– Dimitry K
Nov 15 '17 at 15:59
add a comment |
I think installing wget
via Chocolatey is the easiest way.
- Install Chocolatey
- From the command-line, type:
choco install wget
- You can then use
wget
from the command line like on *nix systems.
add a comment |
As documented in this SU answer, you can use the following in Powershell:
Import-Module bitstransfer
start-bitstransfer -source http://something/something.ext -destination c:something.ext
add a comment |
An alternative to using gnuwin32 is unxutils which includes wget.
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
add a comment |
If you need a visual Post for Windows, here is one.
You can post data or files with it.
add a comment |
protected by Nifle Nov 10 '14 at 9:49
Thank you for your interest in this question.
Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?
18 Answers
18
active
oldest
votes
18 Answers
18
active
oldest
votes
active
oldest
votes
active
oldest
votes
Wget for Windows should work.
From the Wget Wiki FAQ:
GNU Wget is a free network utility to retrieve files from the World
Wide Web using HTTP and FTP, the two most widely used Internet
protocols. It works non-interactively, thus enabling work in the
background, after having logged off.
From this section of FAQ, download links are suggested:
Windows Binaries
courtesy of Jernej Simončič: http://eternallybored.org/misc/wget/
from sourceforge: http://gnuwin32.sourceforge.net/packages/wget.htm
[...]
Link with courtesy of Jernej Simončič is used instead.
8
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
12
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
4
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
1
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
1
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
|
show 5 more comments
Wget for Windows should work.
From the Wget Wiki FAQ:
GNU Wget is a free network utility to retrieve files from the World
Wide Web using HTTP and FTP, the two most widely used Internet
protocols. It works non-interactively, thus enabling work in the
background, after having logged off.
From this section of FAQ, download links are suggested:
Windows Binaries
courtesy of Jernej Simončič: http://eternallybored.org/misc/wget/
from sourceforge: http://gnuwin32.sourceforge.net/packages/wget.htm
[...]
Link with courtesy of Jernej Simončič is used instead.
8
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
12
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
4
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
1
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
1
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
|
show 5 more comments
Wget for Windows should work.
From the Wget Wiki FAQ:
GNU Wget is a free network utility to retrieve files from the World
Wide Web using HTTP and FTP, the two most widely used Internet
protocols. It works non-interactively, thus enabling work in the
background, after having logged off.
From this section of FAQ, download links are suggested:
Windows Binaries
courtesy of Jernej Simončič: http://eternallybored.org/misc/wget/
from sourceforge: http://gnuwin32.sourceforge.net/packages/wget.htm
[...]
Link with courtesy of Jernej Simončič is used instead.
Wget for Windows should work.
From the Wget Wiki FAQ:
GNU Wget is a free network utility to retrieve files from the World
Wide Web using HTTP and FTP, the two most widely used Internet
protocols. It works non-interactively, thus enabling work in the
background, after having logged off.
From this section of FAQ, download links are suggested:
Windows Binaries
courtesy of Jernej Simončič: http://eternallybored.org/misc/wget/
from sourceforge: http://gnuwin32.sourceforge.net/packages/wget.htm
[...]
Link with courtesy of Jernej Simončič is used instead.
edited Nov 21 '15 at 11:10
community wiki
3 revs, 3 users 57%
clearkimura
8
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
12
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
4
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
1
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
1
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
|
show 5 more comments
8
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
12
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
4
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
1
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
1
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
8
8
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
There's also Winwget cybershade.us/winwget if you prefer a gui
– Col
Aug 19 '09 at 11:47
12
12
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
The standalone version is downloadable from this link.
– Vito Gentile
Feb 24 '14 at 11:19
4
4
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
More recent, even up-to-date (as of today) Windows builds, provided by Jernej Simončič
– Gras Double
Feb 16 '15 at 19:37
1
1
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
@cixelsyd Updated link to alternative source.
– clearkimura
Nov 21 '15 at 11:11
1
1
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
eternallybored.org/misc/wget/ is flagged by enterprise antivirus on my system. Carbon Black / Bit 9. Probably false positive. But sourceforge one runs. Does not support sslv3.
– TamusJRoyce
Jan 12 at 5:22
|
show 5 more comments
An alternative I discovered recently, using PowerShell:
$client = new-object System.Net.WebClient
$client.DownloadFile("http://www.xyz.net/file.txt","C:tmpfile.txt")
It works as well with GET queries.
If you need to specify credentials to download the file, add the following line in between:
$client.Credentials = Get-Credential
A standard windows credentials prompt will pop up. The credentials you enter there will be used to download the file. You only need to do this once for all the time you will be using the $client object.
82
You can also do it in one-line:(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
15
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
8
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
3
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
4
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
|
show 9 more comments
An alternative I discovered recently, using PowerShell:
$client = new-object System.Net.WebClient
$client.DownloadFile("http://www.xyz.net/file.txt","C:tmpfile.txt")
It works as well with GET queries.
If you need to specify credentials to download the file, add the following line in between:
$client.Credentials = Get-Credential
A standard windows credentials prompt will pop up. The credentials you enter there will be used to download the file. You only need to do this once for all the time you will be using the $client object.
82
You can also do it in one-line:(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
15
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
8
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
3
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
4
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
|
show 9 more comments
An alternative I discovered recently, using PowerShell:
$client = new-object System.Net.WebClient
$client.DownloadFile("http://www.xyz.net/file.txt","C:tmpfile.txt")
It works as well with GET queries.
If you need to specify credentials to download the file, add the following line in between:
$client.Credentials = Get-Credential
A standard windows credentials prompt will pop up. The credentials you enter there will be used to download the file. You only need to do this once for all the time you will be using the $client object.
An alternative I discovered recently, using PowerShell:
$client = new-object System.Net.WebClient
$client.DownloadFile("http://www.xyz.net/file.txt","C:tmpfile.txt")
It works as well with GET queries.
If you need to specify credentials to download the file, add the following line in between:
$client.Credentials = Get-Credential
A standard windows credentials prompt will pop up. The credentials you enter there will be used to download the file. You only need to do this once for all the time you will be using the $client object.
edited Mar 7 '16 at 15:00
community wiki
5 revs, 4 users 36%
Ubeogesh
82
You can also do it in one-line:(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
15
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
8
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
3
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
4
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
|
show 9 more comments
82
You can also do it in one-line:(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
15
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
8
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
3
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
4
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
82
82
You can also do it in one-line:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
You can also do it in one-line:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt','C:tmpfile.txt')
– schellack
Oct 14 '11 at 20:32
15
15
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
@Rob powershell is built in to Windows...
– nhinkle♦
Dec 14 '12 at 4:22
8
8
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
From Vista up, yes.
– Arran
Dec 19 '12 at 12:44
3
3
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
@BrainSlugs83, absolutely, but many, many, people are still using XP. It's merely something to bear in mind.
– Arran
May 7 '13 at 8:08
4
4
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
@BrainSlugs83, you underestimate the amount of people still on older Windows systems. I don't understand the issue, I pointed out it's only on Vista upwards. People can choose to ignore it, or say "hey thanks!", but you....? If you have an issue, create a chat and we can talk. Someone with rep (like you) should realise here is not the place for this discussion.
– Arran
Jun 4 '13 at 21:17
|
show 9 more comments
If you have PowerShell >= 3.0, you can use
Invoke-WebRequest
Invoke-WebRequest -OutFile index.html http://superuser.com
Or golfed
iwr -outf index.html http://superuser.com
Download a file via HTTP in Windows
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed toSystem.Net.WebClient
. However you can makeInvoke-WebRequest
work by adding-UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.
– Ela782
Jan 7 '16 at 12:22
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
add a comment |
If you have PowerShell >= 3.0, you can use
Invoke-WebRequest
Invoke-WebRequest -OutFile index.html http://superuser.com
Or golfed
iwr -outf index.html http://superuser.com
Download a file via HTTP in Windows
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed toSystem.Net.WebClient
. However you can makeInvoke-WebRequest
work by adding-UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.
– Ela782
Jan 7 '16 at 12:22
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
add a comment |
If you have PowerShell >= 3.0, you can use
Invoke-WebRequest
Invoke-WebRequest -OutFile index.html http://superuser.com
Or golfed
iwr -outf index.html http://superuser.com
Download a file via HTTP in Windows
If you have PowerShell >= 3.0, you can use
Invoke-WebRequest
Invoke-WebRequest -OutFile index.html http://superuser.com
Or golfed
iwr -outf index.html http://superuser.com
Download a file via HTTP in Windows
edited Aug 7 '17 at 3:43
community wiki
7 revs, 3 users 85%
Steven Penny
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed toSystem.Net.WebClient
. However you can makeInvoke-WebRequest
work by adding-UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.
– Ela782
Jan 7 '16 at 12:22
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
add a comment |
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed toSystem.Net.WebClient
. However you can makeInvoke-WebRequest
work by adding-UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.
– Ela782
Jan 7 '16 at 12:22
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed to
System.Net.WebClient
. However you can make Invoke-WebRequest
work by adding -UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.– Ela782
Jan 7 '16 at 12:22
This doesn't work with redirects on sourceforge (and possibly other sites), as opposed to
System.Net.WebClient
. However you can make Invoke-WebRequest
work by adding -UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox
.– Ela782
Jan 7 '16 at 12:22
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
Is there an option to see the progress of the download?
– Franklin Yu
Nov 13 '17 at 19:24
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
@FranklinYu the progress will show if the file is large enough
– Steven Penny
Nov 13 '17 at 19:55
add a comment |
Windows has its own command line download utility - BITSAdmin:
BITSAdmin is a command-line tool that you can use to create download
or upload jobs and monitor their progress.
EDIT: 26.01.15 -
Here's my overview of how a file can be downloaded on windows without external tools
And a complete bitsadmin example:
bitsadmin /transfer myDownloadJob /download /priority normal http://downloadsrv/10mb.zip c:10mb.zip
Edit : 15.05.2018 - turned out that's possible to download a file with certutil too:
certutil.exe -urlcache -split -f "https://download.sysinternals.com/files/PSTools.zip" pstools.zip
Certutil is not installed by default on XP/Win2003 but is avaialble on the newer windows versions.For XP/2003 you'll need the Admin Tool Pack for windows server 2003
7
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
2
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
12
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
1
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
4
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
|
show 3 more comments
Windows has its own command line download utility - BITSAdmin:
BITSAdmin is a command-line tool that you can use to create download
or upload jobs and monitor their progress.
EDIT: 26.01.15 -
Here's my overview of how a file can be downloaded on windows without external tools
And a complete bitsadmin example:
bitsadmin /transfer myDownloadJob /download /priority normal http://downloadsrv/10mb.zip c:10mb.zip
Edit : 15.05.2018 - turned out that's possible to download a file with certutil too:
certutil.exe -urlcache -split -f "https://download.sysinternals.com/files/PSTools.zip" pstools.zip
Certutil is not installed by default on XP/Win2003 but is avaialble on the newer windows versions.For XP/2003 you'll need the Admin Tool Pack for windows server 2003
7
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
2
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
12
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
1
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
4
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
|
show 3 more comments
Windows has its own command line download utility - BITSAdmin:
BITSAdmin is a command-line tool that you can use to create download
or upload jobs and monitor their progress.
EDIT: 26.01.15 -
Here's my overview of how a file can be downloaded on windows without external tools
And a complete bitsadmin example:
bitsadmin /transfer myDownloadJob /download /priority normal http://downloadsrv/10mb.zip c:10mb.zip
Edit : 15.05.2018 - turned out that's possible to download a file with certutil too:
certutil.exe -urlcache -split -f "https://download.sysinternals.com/files/PSTools.zip" pstools.zip
Certutil is not installed by default on XP/Win2003 but is avaialble on the newer windows versions.For XP/2003 you'll need the Admin Tool Pack for windows server 2003
Windows has its own command line download utility - BITSAdmin:
BITSAdmin is a command-line tool that you can use to create download
or upload jobs and monitor their progress.
EDIT: 26.01.15 -
Here's my overview of how a file can be downloaded on windows without external tools
And a complete bitsadmin example:
bitsadmin /transfer myDownloadJob /download /priority normal http://downloadsrv/10mb.zip c:10mb.zip
Edit : 15.05.2018 - turned out that's possible to download a file with certutil too:
certutil.exe -urlcache -split -f "https://download.sysinternals.com/files/PSTools.zip" pstools.zip
Certutil is not installed by default on XP/Win2003 but is avaialble on the newer windows versions.For XP/2003 you'll need the Admin Tool Pack for windows server 2003
edited May 15 at 15:52
community wiki
6 revs, 3 users 71%
npocmaka
7
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
2
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
12
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
1
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
4
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
|
show 3 more comments
7
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
2
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
12
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
1
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
4
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
7
7
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
Interesting. That is one clumsy piece of software compared to wget.
– Matt H
Mar 28 '12 at 21:36
2
2
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
Note that It doesn't ship with Windows XP, and maybe not with other versions either.
– Ian Dunn
May 22 '12 at 23:06
12
12
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
Update: BITSAdmin is deprecated and is not guaranteed to be available in future versions of Windows. Administrative tools for the BITS service are now provided by BITS PowerShell cmdlets.
– nulldev07
Sep 28 '12 at 5:49
1
1
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
@MattH: because it's nto suppsoed to be wget in the first place? - see en.wikipedia.org/wiki/Background_Intelligent_Transfer_Service
– peterchen
Sep 27 '13 at 12:17
4
4
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
Unable to add file - 0x80070057
– Tomáš Zato
Apr 26 '16 at 17:55
|
show 3 more comments
Save the following text as wget.js
and simply call
cscript /nologo wget.js http://example.com
This is the code:
var WinHttpReq = new ActiveXObject("WinHttp.WinHttpRequest.5.1");
WinHttpReq.Open("GET", WScript.Arguments(0), /*async=*/false);
WinHttpReq.Send();
WScript.Echo(WinHttpReq.ResponseText);
/* To save a binary file use this code instead of previous line
BinStream = new ActiveXObject("ADODB.Stream");
BinStream.Type = 1;
BinStream.Open();
BinStream.Write(WinHttpReq.ResponseBody);
BinStream.SaveToFile("out.bin");
*/
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
1
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
4
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
add a comment |
Save the following text as wget.js
and simply call
cscript /nologo wget.js http://example.com
This is the code:
var WinHttpReq = new ActiveXObject("WinHttp.WinHttpRequest.5.1");
WinHttpReq.Open("GET", WScript.Arguments(0), /*async=*/false);
WinHttpReq.Send();
WScript.Echo(WinHttpReq.ResponseText);
/* To save a binary file use this code instead of previous line
BinStream = new ActiveXObject("ADODB.Stream");
BinStream.Type = 1;
BinStream.Open();
BinStream.Write(WinHttpReq.ResponseBody);
BinStream.SaveToFile("out.bin");
*/
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
1
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
4
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
add a comment |
Save the following text as wget.js
and simply call
cscript /nologo wget.js http://example.com
This is the code:
var WinHttpReq = new ActiveXObject("WinHttp.WinHttpRequest.5.1");
WinHttpReq.Open("GET", WScript.Arguments(0), /*async=*/false);
WinHttpReq.Send();
WScript.Echo(WinHttpReq.ResponseText);
/* To save a binary file use this code instead of previous line
BinStream = new ActiveXObject("ADODB.Stream");
BinStream.Type = 1;
BinStream.Open();
BinStream.Write(WinHttpReq.ResponseBody);
BinStream.SaveToFile("out.bin");
*/
Save the following text as wget.js
and simply call
cscript /nologo wget.js http://example.com
This is the code:
var WinHttpReq = new ActiveXObject("WinHttp.WinHttpRequest.5.1");
WinHttpReq.Open("GET", WScript.Arguments(0), /*async=*/false);
WinHttpReq.Send();
WScript.Echo(WinHttpReq.ResponseText);
/* To save a binary file use this code instead of previous line
BinStream = new ActiveXObject("ADODB.Stream");
BinStream.Type = 1;
BinStream.Open();
BinStream.Write(WinHttpReq.ResponseBody);
BinStream.SaveToFile("out.bin");
*/
edited Jan 15 '13 at 8:48
community wiki
user190042
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
1
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
4
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
add a comment |
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
1
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
4
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
What language is this script in?Looks useful to my current task. I'd like to find more reference documentation. Doesn't look quite like vb
– G-.
May 30 '14 at 14:54
1
1
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
Useful for single files. Needs enhancing for recursive download and https.
– opticyclic
Nov 26 '14 at 19:07
4
4
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
@G-. I'm late to the party, but that's JavaScript.
– prooffreader
Oct 21 '15 at 20:52
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
I tried to do that for database.clamav.net/daily.cvd, but it downloaded only 88kB of 44MB :(
– kokbira
Oct 10 '17 at 16:27
add a comment |
I made a quick myGet.bat file which calls the PowerShell method described above.
@Echo OFF
SetLocal EnableDelayedExpansion
Set Var=%1
Set Var=!Var:http://=!
Set Var=!Var:/=,!
Set Var=!Var:%%20=?!
Set Var=!Var: =?!
Call :LOOP !var!
Echo.Downloading: %1 to %~p0!FN!
powershell.exe -Command (new-object System.Net.WebClient).DownloadFile('%1','%~p0!FN!')
GoTo :EOF
:LOOP
If "%1"=="" GoTo :EOF
Set FN=%1
Set FN=!FN:?= !
Shift
GoTo :LOOP
I borrowed some code from Parsing URL for filename with space.
1
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
add a comment |
I made a quick myGet.bat file which calls the PowerShell method described above.
@Echo OFF
SetLocal EnableDelayedExpansion
Set Var=%1
Set Var=!Var:http://=!
Set Var=!Var:/=,!
Set Var=!Var:%%20=?!
Set Var=!Var: =?!
Call :LOOP !var!
Echo.Downloading: %1 to %~p0!FN!
powershell.exe -Command (new-object System.Net.WebClient).DownloadFile('%1','%~p0!FN!')
GoTo :EOF
:LOOP
If "%1"=="" GoTo :EOF
Set FN=%1
Set FN=!FN:?= !
Shift
GoTo :LOOP
I borrowed some code from Parsing URL for filename with space.
1
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
add a comment |
I made a quick myGet.bat file which calls the PowerShell method described above.
@Echo OFF
SetLocal EnableDelayedExpansion
Set Var=%1
Set Var=!Var:http://=!
Set Var=!Var:/=,!
Set Var=!Var:%%20=?!
Set Var=!Var: =?!
Call :LOOP !var!
Echo.Downloading: %1 to %~p0!FN!
powershell.exe -Command (new-object System.Net.WebClient).DownloadFile('%1','%~p0!FN!')
GoTo :EOF
:LOOP
If "%1"=="" GoTo :EOF
Set FN=%1
Set FN=!FN:?= !
Shift
GoTo :LOOP
I borrowed some code from Parsing URL for filename with space.
I made a quick myGet.bat file which calls the PowerShell method described above.
@Echo OFF
SetLocal EnableDelayedExpansion
Set Var=%1
Set Var=!Var:http://=!
Set Var=!Var:/=,!
Set Var=!Var:%%20=?!
Set Var=!Var: =?!
Call :LOOP !var!
Echo.Downloading: %1 to %~p0!FN!
powershell.exe -Command (new-object System.Net.WebClient).DownloadFile('%1','%~p0!FN!')
GoTo :EOF
:LOOP
If "%1"=="" GoTo :EOF
Set FN=%1
Set FN=!FN:?= !
Shift
GoTo :LOOP
I borrowed some code from Parsing URL for filename with space.
edited Mar 16 '15 at 22:22
community wiki
2 revs, 2 users 89%
MartinC
1
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
add a comment |
1
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
1
1
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
why the downvote? this looks okay to me and is a direct response to the question. Yes it's clunky and could use improvement, like escaping ampersands (&) in the url, but it works as is.
– matt wilkie
Apr 24 '13 at 5:02
add a comment |
There is a native cURL for Windows available here. There are many flavors available- with and without SSL support.
You don't need the extra baggage of Cygwin and the likes, just one small EXE file.
It is also important to know that there are both wget
and curl
aliases built into all modern versions of Windows Powershell. They are equivalent.
No extra files or downloads are required to obtain wget
functionality:
Using Curl In Powershell (The Sociable Geek)
Excerpt:
You can type in a cURL command like one that downloads a file from a
GitHub repository.
curl http://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json
and it will seem like it works but what it is actually doing is just
using cURL as an alias. In the above instance, what will happen is
that you will just get the headers instead of the file itself.
Aliases in PowerShell allow you to create shortcuts for longer commands so you don’t have to type them out all of the time.
If you type in the command Get-Alias, it will give you a list of all the Aliases that are used in PowerShell. As you can see, the curl command just calls the Invoke-WebRequest command. They are similar but not the same which is why the above request does not work for us.
To get this to work properly in PowerShell the easiest way is to use variables and the -OutFile
argument as shown here:
(file name cut off in image “https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json”)
This syntax will download the full contents of the target file azuredeploy.json
to the local file newfile.json
The primary advantage is that it is built into Powershell itself so this code will execute directly with no downloads or any other extra file creations are required to make it work on any modern version of Windows.
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
add a comment |
There is a native cURL for Windows available here. There are many flavors available- with and without SSL support.
You don't need the extra baggage of Cygwin and the likes, just one small EXE file.
It is also important to know that there are both wget
and curl
aliases built into all modern versions of Windows Powershell. They are equivalent.
No extra files or downloads are required to obtain wget
functionality:
Using Curl In Powershell (The Sociable Geek)
Excerpt:
You can type in a cURL command like one that downloads a file from a
GitHub repository.
curl http://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json
and it will seem like it works but what it is actually doing is just
using cURL as an alias. In the above instance, what will happen is
that you will just get the headers instead of the file itself.
Aliases in PowerShell allow you to create shortcuts for longer commands so you don’t have to type them out all of the time.
If you type in the command Get-Alias, it will give you a list of all the Aliases that are used in PowerShell. As you can see, the curl command just calls the Invoke-WebRequest command. They are similar but not the same which is why the above request does not work for us.
To get this to work properly in PowerShell the easiest way is to use variables and the -OutFile
argument as shown here:
(file name cut off in image “https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json”)
This syntax will download the full contents of the target file azuredeploy.json
to the local file newfile.json
The primary advantage is that it is built into Powershell itself so this code will execute directly with no downloads or any other extra file creations are required to make it work on any modern version of Windows.
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
add a comment |
There is a native cURL for Windows available here. There are many flavors available- with and without SSL support.
You don't need the extra baggage of Cygwin and the likes, just one small EXE file.
It is also important to know that there are both wget
and curl
aliases built into all modern versions of Windows Powershell. They are equivalent.
No extra files or downloads are required to obtain wget
functionality:
Using Curl In Powershell (The Sociable Geek)
Excerpt:
You can type in a cURL command like one that downloads a file from a
GitHub repository.
curl http://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json
and it will seem like it works but what it is actually doing is just
using cURL as an alias. In the above instance, what will happen is
that you will just get the headers instead of the file itself.
Aliases in PowerShell allow you to create shortcuts for longer commands so you don’t have to type them out all of the time.
If you type in the command Get-Alias, it will give you a list of all the Aliases that are used in PowerShell. As you can see, the curl command just calls the Invoke-WebRequest command. They are similar but not the same which is why the above request does not work for us.
To get this to work properly in PowerShell the easiest way is to use variables and the -OutFile
argument as shown here:
(file name cut off in image “https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json”)
This syntax will download the full contents of the target file azuredeploy.json
to the local file newfile.json
The primary advantage is that it is built into Powershell itself so this code will execute directly with no downloads or any other extra file creations are required to make it work on any modern version of Windows.
There is a native cURL for Windows available here. There are many flavors available- with and without SSL support.
You don't need the extra baggage of Cygwin and the likes, just one small EXE file.
It is also important to know that there are both wget
and curl
aliases built into all modern versions of Windows Powershell. They are equivalent.
No extra files or downloads are required to obtain wget
functionality:
Using Curl In Powershell (The Sociable Geek)
Excerpt:
You can type in a cURL command like one that downloads a file from a
GitHub repository.
curl http://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json
and it will seem like it works but what it is actually doing is just
using cURL as an alias. In the above instance, what will happen is
that you will just get the headers instead of the file itself.
Aliases in PowerShell allow you to create shortcuts for longer commands so you don’t have to type them out all of the time.
If you type in the command Get-Alias, it will give you a list of all the Aliases that are used in PowerShell. As you can see, the curl command just calls the Invoke-WebRequest command. They are similar but not the same which is why the above request does not work for us.
To get this to work properly in PowerShell the easiest way is to use variables and the -OutFile
argument as shown here:
(file name cut off in image “https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/mongodb-on-ubuntu/azuredeploy.json”)
This syntax will download the full contents of the target file azuredeploy.json
to the local file newfile.json
The primary advantage is that it is built into Powershell itself so this code will execute directly with no downloads or any other extra file creations are required to make it work on any modern version of Windows.
edited Nov 15 '17 at 18:21
community wiki
6 revs, 4 users 84%
SDsolar
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
add a comment |
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
This be done directly on one line, but the line gets pretty long and is not as immediately readable at a glance.
– SDsolar
Nov 15 '17 at 18:48
add a comment |
I was searching for the same, and since I had no privilege to install any of the above packages, I went for a small workaround (to download 30+files):
- I created a batch file
- Listed all the files
- Put
firefox.exe
at the beginning of each line - Went to the firefox directory in
Program Files
- Ran it.
add a comment |
I was searching for the same, and since I had no privilege to install any of the above packages, I went for a small workaround (to download 30+files):
- I created a batch file
- Listed all the files
- Put
firefox.exe
at the beginning of each line - Went to the firefox directory in
Program Files
- Ran it.
add a comment |
I was searching for the same, and since I had no privilege to install any of the above packages, I went for a small workaround (to download 30+files):
- I created a batch file
- Listed all the files
- Put
firefox.exe
at the beginning of each line - Went to the firefox directory in
Program Files
- Ran it.
I was searching for the same, and since I had no privilege to install any of the above packages, I went for a small workaround (to download 30+files):
- I created a batch file
- Listed all the files
- Put
firefox.exe
at the beginning of each line - Went to the firefox directory in
Program Files
- Ran it.
edited Mar 16 '15 at 22:24
community wiki
4 revs, 4 users 41%
Simon
add a comment |
add a comment |
If PowerShell is an option, that's the preferred route, since you (potentially) won't have to install anything extra:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt', 'C:tmpfile.tx??t')
Failing that, Wget for Windows, as others have pointed out is definitely the second best option. As posted in another answer it looks like you can download Wget all by itself, or you can grab it as a part of Cygwin or MSys.
If for some reason, you find yourself stuck in a time warp, using a machine that doesn't have PowerShell and you have zero access to a working web browser (that is, Internet Explorer is the only browser on the system, and its settings are corrupt), and your file is on an FTP site (as opposed to HTTP):
start->run "FTP", press "OK".
If memory serves it's been there since Windows 98, and I can confirm that it is still there in Windows 8 RTM (you might have to go into appwiz.cpl
and add/remove features to get it). This utility can both download and upload files to/from FTP sites on the web. It can also be used in scripts to automate either operation.
This tool being built-in has been a real life saver for me in the past, especially in the days of ftp.cdrom.com -- I downloaded Firefox that way once, on a completely broken machine that had only a dial-up Internet connection (back when sneakernet's maximum packet size was still 1.44 MB, and Firefox was still called "Netscape" /me does trollface).
A couple of tips: it's its own command processor, and it has its own syntax. Try typing "help". All FTP sites require a username and password; but if they allow "anonymous" users, the username is "anonymous" and the password is your email address (you can make one up if you don't want to be tracked, but usually there is some kind of logic to make sure it's a valid email address).
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
I'm not sure why you have two question marks in the destination fileC:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
add a comment |
If PowerShell is an option, that's the preferred route, since you (potentially) won't have to install anything extra:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt', 'C:tmpfile.tx??t')
Failing that, Wget for Windows, as others have pointed out is definitely the second best option. As posted in another answer it looks like you can download Wget all by itself, or you can grab it as a part of Cygwin or MSys.
If for some reason, you find yourself stuck in a time warp, using a machine that doesn't have PowerShell and you have zero access to a working web browser (that is, Internet Explorer is the only browser on the system, and its settings are corrupt), and your file is on an FTP site (as opposed to HTTP):
start->run "FTP", press "OK".
If memory serves it's been there since Windows 98, and I can confirm that it is still there in Windows 8 RTM (you might have to go into appwiz.cpl
and add/remove features to get it). This utility can both download and upload files to/from FTP sites on the web. It can also be used in scripts to automate either operation.
This tool being built-in has been a real life saver for me in the past, especially in the days of ftp.cdrom.com -- I downloaded Firefox that way once, on a completely broken machine that had only a dial-up Internet connection (back when sneakernet's maximum packet size was still 1.44 MB, and Firefox was still called "Netscape" /me does trollface).
A couple of tips: it's its own command processor, and it has its own syntax. Try typing "help". All FTP sites require a username and password; but if they allow "anonymous" users, the username is "anonymous" and the password is your email address (you can make one up if you don't want to be tracked, but usually there is some kind of logic to make sure it's a valid email address).
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
I'm not sure why you have two question marks in the destination fileC:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
add a comment |
If PowerShell is an option, that's the preferred route, since you (potentially) won't have to install anything extra:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt', 'C:tmpfile.tx??t')
Failing that, Wget for Windows, as others have pointed out is definitely the second best option. As posted in another answer it looks like you can download Wget all by itself, or you can grab it as a part of Cygwin or MSys.
If for some reason, you find yourself stuck in a time warp, using a machine that doesn't have PowerShell and you have zero access to a working web browser (that is, Internet Explorer is the only browser on the system, and its settings are corrupt), and your file is on an FTP site (as opposed to HTTP):
start->run "FTP", press "OK".
If memory serves it's been there since Windows 98, and I can confirm that it is still there in Windows 8 RTM (you might have to go into appwiz.cpl
and add/remove features to get it). This utility can both download and upload files to/from FTP sites on the web. It can also be used in scripts to automate either operation.
This tool being built-in has been a real life saver for me in the past, especially in the days of ftp.cdrom.com -- I downloaded Firefox that way once, on a completely broken machine that had only a dial-up Internet connection (back when sneakernet's maximum packet size was still 1.44 MB, and Firefox was still called "Netscape" /me does trollface).
A couple of tips: it's its own command processor, and it has its own syntax. Try typing "help". All FTP sites require a username and password; but if they allow "anonymous" users, the username is "anonymous" and the password is your email address (you can make one up if you don't want to be tracked, but usually there is some kind of logic to make sure it's a valid email address).
If PowerShell is an option, that's the preferred route, since you (potentially) won't have to install anything extra:
(new-object System.Net.WebClient).DownloadFile('http://www.xyz.net/file.txt', 'C:tmpfile.tx??t')
Failing that, Wget for Windows, as others have pointed out is definitely the second best option. As posted in another answer it looks like you can download Wget all by itself, or you can grab it as a part of Cygwin or MSys.
If for some reason, you find yourself stuck in a time warp, using a machine that doesn't have PowerShell and you have zero access to a working web browser (that is, Internet Explorer is the only browser on the system, and its settings are corrupt), and your file is on an FTP site (as opposed to HTTP):
start->run "FTP", press "OK".
If memory serves it's been there since Windows 98, and I can confirm that it is still there in Windows 8 RTM (you might have to go into appwiz.cpl
and add/remove features to get it). This utility can both download and upload files to/from FTP sites on the web. It can also be used in scripts to automate either operation.
This tool being built-in has been a real life saver for me in the past, especially in the days of ftp.cdrom.com -- I downloaded Firefox that way once, on a completely broken machine that had only a dial-up Internet connection (back when sneakernet's maximum packet size was still 1.44 MB, and Firefox was still called "Netscape" /me does trollface).
A couple of tips: it's its own command processor, and it has its own syntax. Try typing "help". All FTP sites require a username and password; but if they allow "anonymous" users, the username is "anonymous" and the password is your email address (you can make one up if you don't want to be tracked, but usually there is some kind of logic to make sure it's a valid email address).
edited Jan 9 '15 at 12:11
community wiki
2 revs, 2 users 67%
BrainSlugs83
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
I'm not sure why you have two question marks in the destination fileC:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
add a comment |
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
I'm not sure why you have two question marks in the destination fileC:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
+1 for thinking of command line ftp! However wget and powershell were both mentioned well before you joined the party, so -1 there. :-/
– matt wilkie
Apr 24 '13 at 5:08
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
The other powershell answers I saw were all multi-liners and/or had some code smell to them -- this is a short & simple one liner to download a file. -- Also I wanted to provide an answer that covered all the bases. :-)
– BrainSlugs83
Jan 12 '16 at 0:20
I'm not sure why you have two question marks in the destination file
C:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
I'm not sure why you have two question marks in the destination file
C:tmpfile.tx??t
– Ploni
Feb 7 at 23:44
add a comment |
And http://www.httrack.com/ has a nice GUI (and it's free), for mirroring sites. It also has a Linux version.
add a comment |
And http://www.httrack.com/ has a nice GUI (and it's free), for mirroring sites. It also has a Linux version.
add a comment |
And http://www.httrack.com/ has a nice GUI (and it's free), for mirroring sites. It also has a Linux version.
And http://www.httrack.com/ has a nice GUI (and it's free), for mirroring sites. It also has a Linux version.
edited Feb 25 '15 at 23:45
community wiki
2 revs, 2 users 50%
Zsolt Botykai
add a comment |
add a comment |
Cygwin has Wget (and many more utilities).
add a comment |
Cygwin has Wget (and many more utilities).
add a comment |
Cygwin has Wget (and many more utilities).
Cygwin has Wget (and many more utilities).
edited Mar 16 '15 at 22:19
community wiki
2 revs, 2 users 50%
Rich Homolka
add a comment |
add a comment |
You can get WGet for Windows here. Alternatively you can right click on the download link of the item you want to download and choose Save As. This will download the file and not open it in the assigned application.
add a comment |
You can get WGet for Windows here. Alternatively you can right click on the download link of the item you want to download and choose Save As. This will download the file and not open it in the assigned application.
add a comment |
You can get WGet for Windows here. Alternatively you can right click on the download link of the item you want to download and choose Save As. This will download the file and not open it in the assigned application.
You can get WGet for Windows here. Alternatively you can right click on the download link of the item you want to download and choose Save As. This will download the file and not open it in the assigned application.
answered Aug 19 '09 at 11:46
community wiki
BinaryMisfit
add a comment |
add a comment |
If you want a GUI, then try VisualWget, which is actually clean, and feature full. It is based on GNU Wget for its download engine.
EDIT: updated link.
1
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
add a comment |
If you want a GUI, then try VisualWget, which is actually clean, and feature full. It is based on GNU Wget for its download engine.
EDIT: updated link.
1
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
add a comment |
If you want a GUI, then try VisualWget, which is actually clean, and feature full. It is based on GNU Wget for its download engine.
EDIT: updated link.
If you want a GUI, then try VisualWget, which is actually clean, and feature full. It is based on GNU Wget for its download engine.
EDIT: updated link.
edited Mar 24 '13 at 17:52
community wiki
Wurlitzer
1
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
add a comment |
1
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
1
1
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
here is an updated link: sites.google.com/site/visualwget/… (the downloads are at the bottom of the page, use the little arrows on the right)
– Reed Hedges
May 13 '12 at 12:43
add a comment |
You could also use the wget
packaged in PowerShell. ;^) To open, hit the Windows key and type "powershell" or Windows-R and type "powershell" and hit return.
No installation necessary.
One interesting difference from conventional wget
(more at that link): You can't simply use the greater-than to pipe to a file. wget
in PowerShell is just a convenience wrapper for Invoke-WebRequest
, and you need to use its syntax to write to a file.
wget https://superuser.com/questions/25538 -OutFile rubySlippers.html
1
-OutFile
did the job!
– Dimitry K
Nov 15 '17 at 15:59
add a comment |
You could also use the wget
packaged in PowerShell. ;^) To open, hit the Windows key and type "powershell" or Windows-R and type "powershell" and hit return.
No installation necessary.
One interesting difference from conventional wget
(more at that link): You can't simply use the greater-than to pipe to a file. wget
in PowerShell is just a convenience wrapper for Invoke-WebRequest
, and you need to use its syntax to write to a file.
wget https://superuser.com/questions/25538 -OutFile rubySlippers.html
1
-OutFile
did the job!
– Dimitry K
Nov 15 '17 at 15:59
add a comment |
You could also use the wget
packaged in PowerShell. ;^) To open, hit the Windows key and type "powershell" or Windows-R and type "powershell" and hit return.
No installation necessary.
One interesting difference from conventional wget
(more at that link): You can't simply use the greater-than to pipe to a file. wget
in PowerShell is just a convenience wrapper for Invoke-WebRequest
, and you need to use its syntax to write to a file.
wget https://superuser.com/questions/25538 -OutFile rubySlippers.html
You could also use the wget
packaged in PowerShell. ;^) To open, hit the Windows key and type "powershell" or Windows-R and type "powershell" and hit return.
No installation necessary.
One interesting difference from conventional wget
(more at that link): You can't simply use the greater-than to pipe to a file. wget
in PowerShell is just a convenience wrapper for Invoke-WebRequest
, and you need to use its syntax to write to a file.
wget https://superuser.com/questions/25538 -OutFile rubySlippers.html
edited Mar 20 '17 at 10:17
community wiki
2 revs
ruffin
1
-OutFile
did the job!
– Dimitry K
Nov 15 '17 at 15:59
add a comment |
1
-OutFile
did the job!
– Dimitry K
Nov 15 '17 at 15:59
1
1
-OutFile
did the job!– Dimitry K
Nov 15 '17 at 15:59
-OutFile
did the job!– Dimitry K
Nov 15 '17 at 15:59
add a comment |
I think installing wget
via Chocolatey is the easiest way.
- Install Chocolatey
- From the command-line, type:
choco install wget
- You can then use
wget
from the command line like on *nix systems.
add a comment |
I think installing wget
via Chocolatey is the easiest way.
- Install Chocolatey
- From the command-line, type:
choco install wget
- You can then use
wget
from the command line like on *nix systems.
add a comment |
I think installing wget
via Chocolatey is the easiest way.
- Install Chocolatey
- From the command-line, type:
choco install wget
- You can then use
wget
from the command line like on *nix systems.
I think installing wget
via Chocolatey is the easiest way.
- Install Chocolatey
- From the command-line, type:
choco install wget
- You can then use
wget
from the command line like on *nix systems.
answered Jun 17 at 11:29
community wiki
sivabudh
add a comment |
add a comment |
As documented in this SU answer, you can use the following in Powershell:
Import-Module bitstransfer
start-bitstransfer -source http://something/something.ext -destination c:something.ext
add a comment |
As documented in this SU answer, you can use the following in Powershell:
Import-Module bitstransfer
start-bitstransfer -source http://something/something.ext -destination c:something.ext
add a comment |
As documented in this SU answer, you can use the following in Powershell:
Import-Module bitstransfer
start-bitstransfer -source http://something/something.ext -destination c:something.ext
As documented in this SU answer, you can use the following in Powershell:
Import-Module bitstransfer
start-bitstransfer -source http://something/something.ext -destination c:something.ext
answered Dec 5 at 19:27
community wiki
Dolan Antenucci
add a comment |
add a comment |
An alternative to using gnuwin32 is unxutils which includes wget.
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
add a comment |
An alternative to using gnuwin32 is unxutils which includes wget.
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
add a comment |
An alternative to using gnuwin32 is unxutils which includes wget.
An alternative to using gnuwin32 is unxutils which includes wget.
answered Jul 21 '11 at 16:00
community wiki
Chris Chilvers
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
add a comment |
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
you can manage with unxutils but it's old, it uses an old version of wget. gnuwin32 is the thing to use. not quite as convenient to install and not as easy to find things, but it has much more than unxutils too.
– barlop
Oct 5 '11 at 19:31
add a comment |
If you need a visual Post for Windows, here is one.
You can post data or files with it.
add a comment |
If you need a visual Post for Windows, here is one.
You can post data or files with it.
add a comment |
If you need a visual Post for Windows, here is one.
You can post data or files with it.
If you need a visual Post for Windows, here is one.
You can post data or files with it.
answered Apr 12 '16 at 7:45
community wiki
Rigel
add a comment |
add a comment |
protected by Nifle Nov 10 '14 at 9:49
Thank you for your interest in this question.
Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?
Just right clicking a file and hitting "Save Target As" or "Save Link As" or "Save As" (language varies depending on your browser) will work.
– BrainSlugs83
Oct 22 '12 at 5:53
21
The point of having a command is being able to write a batch file and run it (perhaps scheduled as a task) anytime you want. That's where the GUI falls short.
– Jbm
Nov 15 '12 at 14:11
3
How do you download with MS Word?
– Jaime Hablutzel
Aug 20 '14 at 12:16
5
@JaimeHablutzel Why would you ever want to download something via MS Word? MS Word is not a terminal.
– Braden Best
May 14 '15 at 20:53
1
@SDsolar Or just upvote/improve this answer below.
– Franklin Yu
Nov 13 '17 at 19:32