은승우

Update app.js

Showing 1 changed file with 3 additions and 2 deletions
......@@ -105,7 +105,8 @@ async function handleEvent(event) {
};
request.post(options, function (error, response, body) {
console.log(body.type);
console.log(document.getElementById(body));
var data= body.toString('utf-8');
var text='';
while(data.indexOf('text\\')!=-1)
......@@ -114,7 +115,7 @@ async function handleEvent(event) {
text+=data.substring(0,data.indexOf("\\"))+" ";
}
text="나의모든날들";
console.log(text);
var url="https://www.genie.co.kr/search/searchLyrics?query="+ encodeURI(text);
request(url, function(error, response, html){
var $ = cheerio.load(html);
......