Wget 与 js 并没有工作 [英] Wget with js and did not work

查看:32
本文介绍了Wget 与 js 并没有工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何下​​载和保存从命令行动态生成的页面?我试过了

wget PageWithJS.com -O output.html

但 output.html 不包含动态生成的代码.

解决方案

wget 不执行 JavaScript.

如果您需要 DOM 在 Javascript 渲染后的样子,请使用 PhantomJS 之类的东西来下载页面.>

How do you download and save a page which is is dynamically generated from the command line? I tried

wget PageWithJS.com -O output.html

but output.html does not contain the dynamically generated code.

解决方案

wget does not execute JavaScript.

If you need the DOM as it loooks after Javascript rendering, use something like PhantomJS to download the page.

这篇关于Wget 与 js 并没有工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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