bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-wget] How to tell wget to strip part following question mark in loc


From: Mark
Subject: [Bug-wget] How to tell wget to strip part following question mark in local filenames?
Date: Wed, 8 May 2013 13:57:42 +0100
User-agent: SquirrelMail/1.4.21

Hi,

I noticed some problems relating to URLs like
  
http://www.example.com/path/to/filename.zip?arg1=somestring&arg2=anotherstring&;...

Wget doesn't strip the ? and following characters from the filename when
creating local files. As far as I can tell it doesn't have an option to do
that. This can cause several problems:

 - Local filenames have "garbage" following the actual extension which the
user has to manually remove.

 - Depending on the web server, each download session may result in unique
arguments in the URL (e.g. some kind of session ID), making it impossible
to easily resume downloading partially-downloaded files. Wget would
instead re-download the whole file, saving it under a different name.

 - The worst problem is that when the arguments following the actual
filename in the URL are very long, wget is unable to create the file at
all, reporting
  File name too long

So this message is to suggest adding an option to tell wget to strip a
question mark and everything after that from the filename part of URLs to
get the local file name.


-- Mark





reply via email to

[Prev in Thread] Current Thread [Next in Thread]