Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The following link image has a space: XA509LA_190x170.jpg

I can get the image using:

wget " XA509LA_190x170.jpg"

However, as I have multiple links, I am doing it using a file, like this:

wget -i image_links.txt

The "wget" commmand won't read the links with spaces from the file. I have try using the following links inside the file (double comma, backslash before the space):

" XA509LA_190x170.jpg"
"\ XA509LA_190x170.jpg"

But none of them work. Does anyone know how I can get it working?

share|improve this question

If you put each HTTP URL on a line of its own, it should work: with space1 with space2

This works for me (GNU wget 1.11.4).

Alternatively, you can URL-escape the spaces, by replacing them with %20, as in
share|improve this answer

Put each URL on one line and make sure to use UNIX line endings for the .txt file.

I used the following script provided by Python to accomplish this in Windows:

python C:\Python27\Tools\scripts\ textfile.txt
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .