我收到一个错误,说“木偶人没有定义”,而它显然是在唯一的javaScript文件中。 如何让JavaScript/single page html项目识别puppeteer模块?我已经研究了这个可能的答案;[Nodejs. Proper way to include modules,然而它没有帮助。 (目标是启动html页面,输入来自booking.com的url,单击按钮,并在控制台中返回抓取的酒店名称、评级等) app.js function main()
{
var Url = document.getElementById('inputUrl').value
我想要做的是有一个按钮,你可以点击它来刷新评论部分,而不需要重新加载页面。这看起来应该很简单,但我就是搞不懂Ajax。
(现在还没有按钮,只是一个间隔)
setInterval(function(){
$(".commentswrapper").load("html");
}, 10000);
Failed to load resource: the server responded with a status of 404 (Not Found)
localhost:8888/post-title/html
(http://从链接中省略,因