곽교린

Feat loading next comment page button

...@@ -40,6 +40,7 @@ function showcomment(response, VideoNum){ ...@@ -40,6 +40,7 @@ function showcomment(response, VideoNum){
40 <iframe width="560" height="315" src="https://www.youtube.com/embed/${VideoNum}" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe> 40 <iframe width="560" height="315" src="https://www.youtube.com/embed/${VideoNum}" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
41 41
42 <br> 42 <br>
43 + <a href="http://localhost:3000/search?videourl=${VideoNum}&nextpage=${savednpt}"><input type="button" value="댓글 더 불러오기"></a>
43 <br> 44 <br>
44 ${commentDisplay} 45 ${commentDisplay}
45 </body> 46 </body>
...@@ -122,8 +123,8 @@ var app = http.createServer(function(request,response){ // request는 브라우 ...@@ -122,8 +123,8 @@ var app = http.createServer(function(request,response){ // request는 브라우
122 commentNum = 0; //코멘트 리스트 초기화 123 commentNum = 0; //코멘트 리스트 초기화
123 124
124 videoNum = queryData.videourl; 125 videoNum = queryData.videourl;
125 - console.log(videoNum);
126 let npt = "" 126 let npt = ""
127 + if(queryData.nextpage != null) npt = queryData.nextpage
127 loadcomment(apiKey,videoNum,npt,2, response); 128 loadcomment(apiKey,videoNum,npt,2, response);
128 } 129 }
129 }); 130 });
......