解决办法:2楼
---------------------------------
同样的文件,比如文件名是ubuntu
用chrome下载,得到的文件就是ubuntu
用wget下载,得到的文件就是CUGf3pywo1ohL
可以指定文件名:wget http://**** -O ubuntu
要是下100个文件怎么办?
有没有办法让wget保持文件名?
[已解决]wget-------->怎样保持文件名
- youzhiyili
- 帖子: 2422
- 注册时间: 2012-03-22 20:42
- 系统: ubuntu22.04
[已解决]wget-------->怎样保持文件名
上次由 youzhiyili 在 2012-12-10 19:53,总共编辑 1 次。
@自由建客 @qy117121 @枫叶饭团 @cikekid @YeLee @jtshs256 @eexpress @ljj_jjl2008 @zhw2101024 @TeliuTe @月下叹逍遥 @leeaman @懒蜗牛Gentoo @灰色小狼 @photor @adagio @JiangHui @phoenixlzx @oneleaf
- oneleaf
- 论坛管理员
- 帖子: 10455
- 注册时间: 2005-03-27 0:06
- 系统: Ubuntu 12.04
Re: wget-------->怎样保持文件名
试试
wget --content-disposition
wget --content-disposition
- youzhiyili
- 帖子: 2422
- 注册时间: 2012-03-22 20:42
- 系统: ubuntu22.04
Re: wget-------->怎样保持文件名
oneleaf 写了:试试
wget --content-disposition

代码: 全选
meme@meme:~/aaa$ ls
meme@meme:~/aaa$ wget --content-disposition http://ubuntuone.com/4cXTUprJssP98cDq10iwGq
--2012-12-10 06:50:39-- http://ubuntuone.com/4cXTUprJssP98cDq10iwGq
Resolving ubuntuone.com (ubuntuone.com)... 91.189.89.204, 91.189.89.205
Connecting to ubuntuone.com (ubuntuone.com)|91.189.89.204|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1707170 (1.6M) [image/jpeg]
Saving to: `background.jpg'
100%[=======================================================================>] 1,707,170 233K/s in 8.5s
2012-12-10 06:50:49 (196 KB/s) - `background.jpg' saved [1707170/1707170]
meme@meme:~/aaa$ ls
background.jpg
meme@meme:~/aaa$
@自由建客 @qy117121 @枫叶饭团 @cikekid @YeLee @jtshs256 @eexpress @ljj_jjl2008 @zhw2101024 @TeliuTe @月下叹逍遥 @leeaman @懒蜗牛Gentoo @灰色小狼 @photor @adagio @JiangHui @phoenixlzx @oneleaf