如何从需求的关键preSS URL wget的 [英] How to wget from URL that needs a key press

查看:177
本文介绍了如何从需求的关键preSS URL wget的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从这个网址下载:

<一个href=\"http://www.histdata.com/download-free-forex-historical-data/?/ascii/1-minute-bar-quotes/eurusd/2014/2\" rel=\"nofollow\">http://www.histdata.com/download-free-forex-historical-data/?/ascii/1-minute-bar-quotes/eurusd/2014/2

在bash 的wget

不过,我需要手动preSS的链接权下载历史数据在这里,

But, I need to manually press the link to right of "Download Historical Data Here"

有没有一种方法,从命令行执行此操作在code?

Is there a way to do this in code from command line?

EDIT 1

或者从Java将是巨大的。

Or from java would be great too.

推荐答案

我想你会需要编写一些code做到这一点,使用支持JavaScript,如一个HTML客户端库PhantomJS ,由答案中提到,以这个问题

I think you will need to write some code to accomplish this, using a html client library that supports Javascript, such as PhantomJS, as mentioned by the answers to this question.

其他选项包括Python的机械化库,并在一些这方面的事情提到回答

Other options include Python's mechanize library, and some of things mentioned in this answer.

如果您在的Java 寻找一个无头的浏览库,我会看看的 的HtmlUnit。
我没有用它虽然个人,所以我不能保证其稳定性或缓解或使用。

If you're looking for a headless browsing library in Java, I would take a look at HtmlUnit. I have not used it personally though, so I can't vouch for its stability or ease or use.

这篇关于如何从需求的关键preSS URL wget的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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