使用wget下载文件 [英] Downloading a file using wget

查看:94
本文介绍了使用wget下载文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用wget从网站下载程序。但是,每当我尝试下载它时,我都会得到一个HTML文件。我正在使用以下语法。

I'm trying to download a program from a website using wget. However, whenever I try to download it I instead get a HTML file. I'm using the following syntax.

wget http://domain.com/downloads/name/

直接点击链接,浏览器将自动尝试下载文件。为什么我得到的是HTML文件而不是我想要的实际文件?

If you go the link directly the browser automatically tries to download the file. Why is that I'm getting the HTML file instead of the actual file I want?

推荐答案

我不认为wget可以像这样为您获取文件,它只会为您提供第一页html,您的页面具有一些延迟代码,而不是文件的直接url,因此您将需要一个真正的浏览器来下载文件

I don't think wget can get the file for you like this, it will just get you the first page html, your page has some delaying code, and not a direct url to the file, so you will need a real browser to download the file

这篇关于使用wget下载文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆