如何使用NodeJs加载HTML页面? 最佳答案 此代码应从html页面加载数据。varhttp=require('http');http.get('http://www.google.com',onGotData);functiononGotData(res){varchunks=[];res.on('data',onGotData);res.on('end',onEnd);functiononGotData(chunk){chunks.push(chunk);}functiononEnd(){console.log(chunks