Showing
13 changed files
with
203 additions
and
310 deletions
testcode/WebTest.js
deleted
100644 → 0
1 | -var express = require('express'); // web server 사용 | ||
2 | -var fs = require('fs'); // file load | ||
3 | - | ||
4 | -var app = express(); | ||
5 | -var port = 80; | ||
6 | - | ||
7 | -app.listen(port, function(){ | ||
8 | - console.log('Server Start'); | ||
9 | -}) | ||
10 | - | ||
11 | -app.get('/', function(req, res){ | ||
12 | - fs.readFile('WebTest.html', function(error, data){ | ||
13 | - if(error){ | ||
14 | - console.log(error); | ||
15 | - }else{ | ||
16 | - res.writeHead(200, {'Content-Type': 'text/html'}); | ||
17 | - res.end(data); | ||
18 | - } | ||
19 | - }) | ||
20 | -}) | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
testcode/app.js
0 → 100644
1 | +var express = require('express'); | ||
2 | +var path = require('path'); | ||
3 | +var bodyParser = require('body-parser'); | ||
4 | +var request = require('request'); | ||
5 | +var fs = require('fs'); | ||
6 | +var ejs = require('ejs'); | ||
7 | +var indexRouter = require('./routes/index'); | ||
8 | +var ncRouter = require('./routes/nc'); | ||
9 | + | ||
10 | +var app = express(); | ||
11 | +const PORT = 80; | ||
12 | + | ||
13 | +app.set('views', path.join(__dirname, 'views')); | ||
14 | +app.set('view engine', 'ejs'); | ||
15 | + | ||
16 | +app.use(express.static(path.join(__dirname, 'public'))); | ||
17 | +app.use(bodyParser.json()); | ||
18 | +app.use(bodyParser.urlencoded({ extended: false })); | ||
19 | + | ||
20 | +app.use('/', indexRouter); | ||
21 | +app.use('/nc', ncRouter); | ||
22 | + | ||
23 | +app.listen(PORT, function(){ | ||
24 | + console.log('Code run in https://localhost:'+PORT+'\n'); | ||
25 | +}); |
... | @@ -12,7 +12,7 @@ const getHtml = async () => { | ... | @@ -12,7 +12,7 @@ const getHtml = async () => { |
12 | }; | 12 | }; |
13 | 13 | ||
14 | 14 | ||
15 | -const getXports = async () => { | 15 | +const getChosun = async () => { |
16 | 16 | ||
17 | return new Promise((resolve, reject) => { | 17 | return new Promise((resolve, reject) => { |
18 | getHtml() | 18 | getHtml() |
... | @@ -42,4 +42,4 @@ const getXports = async () => { | ... | @@ -42,4 +42,4 @@ const getXports = async () => { |
42 | }); | 42 | }); |
43 | }; | 43 | }; |
44 | 44 | ||
45 | -module.exports = getXports; | 45 | +module.exports = getChosun; | ... | ... |
... | @@ -5,7 +5,7 @@ h1,h2,h3,h4,h5,h6{font-weight:normal;font-family:'맑은 고딕','Malgun Gothic' | ... | @@ -5,7 +5,7 @@ h1,h2,h3,h4,h5,h6{font-weight:normal;font-family:'맑은 고딕','Malgun Gothic' |
5 | p,li,dt,dd,span,strong,em,b,input,button,select,textarea,label,a{font-weight:normal;font-family:'맑은 고딕','Malgun Gothic',AppleSDGothicNeo-Regular,Arial,Helvetica,sans-serif;} | 5 | p,li,dt,dd,span,strong,em,b,input,button,select,textarea,label,a{font-weight:normal;font-family:'맑은 고딕','Malgun Gothic',AppleSDGothicNeo-Regular,Arial,Helvetica,sans-serif;} |
6 | a{display:inline-block;vertical-align:top;} | 6 | a{display:inline-block;vertical-align:top;} |
7 | 7 | ||
8 | -h1,h2,h3,h4,h5,h6{margin:0;padding:0;font:inherit;font-weight:bold;} | 8 | +h1,h2,h3,h4,h5,h6{margin:200;padding:200;font:inherit;font-weight:bold;} |
9 | img{display:inline-block;border:0 none;vertical-align:top;} | 9 | img{display:inline-block;border:0 none;vertical-align:top;} |
10 | cite,code,dfn,del,em,ins,label,q,span,strong,b,i,time,mark,font,kbd,q,s,samp,small,strike,sub,sup,tt,var,u,center{display:inline-block;margin:0;padding:0;vertical-align:top;font:inherit;} | 10 | cite,code,dfn,del,em,ins,label,q,span,strong,b,i,time,mark,font,kbd,q,s,samp,small,strike,sub,sup,tt,var,u,center{display:inline-block;margin:0;padding:0;vertical-align:top;font:inherit;} |
11 | address,cite,em,dfn{font:inherit;} | 11 | address,cite,em,dfn{font:inherit;} |
... | @@ -41,7 +41,7 @@ a:focus{color:inherit;} | ... | @@ -41,7 +41,7 @@ a:focus{color:inherit;} |
41 | [class*='title-type'] .tit{font-size:18px;line-height:22px;} | 41 | [class*='title-type'] .tit{font-size:18px;line-height:22px;} |
42 | [class*='title-type'].bold .tit{font-weight:bold;} | 42 | [class*='title-type'].bold .tit{font-weight:bold;} |
43 | [class*='title-type'] .txt{margin-left:6px;color:#666;font-size:10px;line-height:12px;letter-spacing:0;} | 43 | [class*='title-type'] .txt{margin-left:6px;color:#666;font-size:10px;line-height:12px;letter-spacing:0;} |
44 | -[class*='title-type'] .tit+.txt{margin-left:6px;} | 44 | +[class*='title-type'] .tit+.txt{margin-left:20px;} |
45 | 45 | ||
46 | /* =============== List type ======================== */ | 46 | /* =============== List type ======================== */ |
47 | [class*='list-type']{font-size:0;line-height:1;} | 47 | [class*='list-type']{font-size:0;line-height:1;} |
... | @@ -57,8 +57,8 @@ a:focus{color:inherit;} | ... | @@ -57,8 +57,8 @@ a:focus{color:inherit;} |
57 | .display-none{display:none;} | 57 | .display-none{display:none;} |
58 | 58 | ||
59 | /* title-type04 */ | 59 | /* title-type04 */ |
60 | -.title-type04[class*='arr'] .tit{padding-right:17px;} | 60 | +.title-type04[class*='arr'] .tit{padding-right:20px;} |
61 | -.title-type04 .tit{font-size:20px;line-height:22px;} | 61 | +.title-type04 .tit{font-size:40px;line-height:40px;} |
62 | 62 | ||
63 | .img-cover{overflow:hidden;} | 63 | .img-cover{overflow:hidden;} |
64 | 64 | ||
... | @@ -79,3 +79,35 @@ a:focus{color:inherit;} | ... | @@ -79,3 +79,35 @@ a:focus{color:inherit;} |
79 | .list-type038 .info-box01{width:110px;} | 79 | .list-type038 .info-box01{width:110px;} |
80 | .list-type038 .info-box01 .txt-time{padding-top:4px;color:#666;font-size:12px;line-height:14px;letter-spacing:0;} | 80 | .list-type038 .info-box01 .txt-time{padding-top:4px;color:#666;font-size:12px;line-height:14px;letter-spacing:0;} |
81 | .list-type038 .item-box01 .info-box02{width:156px;padding:0 20px 0 0;vertical-align:middle;text-align:right;} | 81 | .list-type038 .item-box01 .info-box02{width:156px;padding:0 20px 0 0;vertical-align:middle;text-align:right;} |
82 | + | ||
83 | +/* 공통여백 */ | ||
84 | +.container>[class*='content']+[class*='content']{margin-top:35px;} | ||
85 | +body:not(.page-main) .container>[class*='content']:last-child{padding-bottom:100px;} | ||
86 | +[class*='box-type']{margin-top:35px;} | ||
87 | +[class*='box-type'] [class*='paging-type01']{margin-top:35px;} | ||
88 | +[class*='tab-content'] [class*='box-type'], | ||
89 | +.title-page02+[class*='box-type'], | ||
90 | +.container>[class*='content']>[class*='box-type']:first-child, | ||
91 | +.section01>[class*='box-type']:first-child, | ||
92 | +.section02>[class*='box-type']:first-child{margin-top:0;} | ||
93 | + | ||
94 | +/* =============== Pager ======================== */ | ||
95 | +/* paging-type01 : 리스트 페이징 */ | ||
96 | +.paging-type01{font-size:0;text-align:center;} | ||
97 | +.paging-type01>a, | ||
98 | +.paging-type01 .num{display:inline-block;height:38px;margin:0 5px;vertical-align:top;} | ||
99 | +.paging-type01 .first, | ||
100 | +.paging-type01 .prev, | ||
101 | +.paging-type01 .next, | ||
102 | +.paging-type01 .last{position:relative;width:29px;height:38px} | ||
103 | +.paging-type01 .first span, | ||
104 | +.paging-type01 .prev span, | ||
105 | +.paging-type01 .next span, | ||
106 | +.paging-type01 .last span{overflow:hidden;position:absolute;top:50%;left:50%;width:11px;height:10px;font-size:1px;color:transparent;margin:-5px 0 0 -5px;background:url(../img/sprites_default01.png?v=20200610_1400) 0 0 no-repeat;} | ||
107 | +.paging-type01 .first span{} | ||
108 | +.paging-type01 .last span{} | ||
109 | +.paging-type01 .prev span{background-position-x:-50px;} | ||
110 | +.paging-type01 .next span{} | ||
111 | +.paging-type01 .num{width:38px;height:38px;font-size:14px;line-height:38px;color:#000;background-color:#ebebeb;} | ||
112 | +.paging-type01 .num.on{color:#fff;background-color:#213989;} | ||
113 | +.paging-type01 .num:not(.on):hover{text-decoration:underline;} | ||
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
1 | var express = require('express'); | 1 | var express = require('express'); |
2 | var router = express.Router(); | 2 | var router = express.Router(); |
3 | 3 | ||
4 | -const getXports = require('../test1.js'); | 4 | +const getXports = require('../xports.js'); |
5 | -const getZum = require('../test2.js'); | 5 | +const getZum = require('../zum.js'); |
6 | -const getChosun = require('../test3.js'); | 6 | +const getChosun = require('../chosun.js'); |
7 | -const getYna = require('../test4.js') | 7 | +const getYna = require('../yna.js') |
8 | 8 | ||
9 | let xports; | 9 | let xports; |
10 | let zum; | 10 | let zum; |
11 | let chosun; | 11 | let chosun; |
12 | let yna; | 12 | let yna; |
13 | +let newslist; | ||
13 | (async function() { | 14 | (async function() { |
14 | try { | 15 | try { |
15 | xports = await getXports(); | 16 | xports = await getXports(); |
16 | zum = await getZum(); | 17 | zum = await getZum(); |
17 | chosun = await getChosun(); | 18 | chosun = await getChosun(); |
18 | yna = await getYna(); | 19 | yna = await getYna(); |
19 | - console.log(xports); | 20 | + |
20 | - console.log(zum); | 21 | + newslist = xports.concat(zum, chosun, yna); |
21 | - console.log(chosun); | 22 | + console.log("index loaded"); |
22 | - console.log(yna); | 23 | + |
23 | } catch (e) { | 24 | } catch (e) { |
24 | return console.log(e); | 25 | return console.log(e); |
25 | } | 26 | } |
... | @@ -28,12 +29,8 @@ try { | ... | @@ -28,12 +29,8 @@ try { |
28 | router.get('/', function(req, res, next){ | 29 | router.get('/', function(req, res, next){ |
29 | 30 | ||
30 | res.render('index', { | 31 | res.render('index', { |
31 | - xports : xports, | 32 | + newslist : newslist |
32 | - zum : zum, | ||
33 | - chosun : chosun, | ||
34 | - yna : yna | ||
35 | }); | 33 | }); |
36 | }); | 34 | }); |
37 | 35 | ||
38 | -console.log("started\n"); | ||
39 | module.exports = router; | 36 | module.exports = router; | ... | ... |
testcode/routes/nc.js
0 → 100644
1 | +var express = require('express'); | ||
2 | +var router = express.Router(); | ||
3 | + | ||
4 | +const getXports = require('../xports.js'); | ||
5 | +const getZum = require('../zum.js'); | ||
6 | +const getChosun = require('../chosun.js'); | ||
7 | +const getYna = require('../yna.js') | ||
8 | + | ||
9 | +let xports; | ||
10 | +let zum; | ||
11 | +let chosun; | ||
12 | +let yna; | ||
13 | +let newslist; | ||
14 | +let nc = new Array(); | ||
15 | +(async function() { | ||
16 | +try { | ||
17 | + xports = await getXports(); | ||
18 | + zum = await getZum(); | ||
19 | + chosun = await getChosun(); | ||
20 | + yna = await getYna(); | ||
21 | + | ||
22 | + newslist = xports.concat(zum, chosun, yna); | ||
23 | + for(var i of newslist){ | ||
24 | + if(i.title.indexOf('NC') !== -1 || i.title.indexOf('nc') !== -1 || i.title.indexOf('엔씨') !== -1 || i.summary.indexOf('NC') !== -1 || i.summary.indexOf('nc') !== -1 || i.summary.indexOf('엔씨') !== -1){ | ||
25 | + nc.push(i); | ||
26 | + } | ||
27 | + } | ||
28 | + console.log("nc loaded"); | ||
29 | + | ||
30 | +} catch (e) { | ||
31 | + return console.log(e); | ||
32 | +} | ||
33 | +})(); | ||
34 | + | ||
35 | +router.get('/', function(req, res, next){ | ||
36 | + | ||
37 | + res.render('nc', { | ||
38 | + nc : nc | ||
39 | + }); | ||
40 | +}); | ||
41 | + | ||
42 | +module.exports = router; |
testcode/testlist.js
deleted
100644 → 0
1 | -var express = require('express'); | ||
2 | -var path = require('path'); | ||
3 | -var bodyParser = require('body-parser'); | ||
4 | -var request = require('request'); | ||
5 | -var fs = require('fs'); | ||
6 | -var ejs = require('ejs'); | ||
7 | -var indexRouter = require('./routes/index'); | ||
8 | - | ||
9 | -var app = express(); | ||
10 | -const PORT = 80; | ||
11 | - | ||
12 | -app.set('views', path.join(__dirname, 'views')); | ||
13 | -app.set('view engine', 'ejs'); | ||
14 | - | ||
15 | -app.use(express.static(path.join(__dirname, 'public'))); | ||
16 | -app.use(bodyParser.json()); | ||
17 | -app.use(bodyParser.urlencoded({ extended: false })); | ||
18 | - | ||
19 | -app.use('/', indexRouter); | ||
20 | - | ||
21 | -app.listen(PORT, function(){ | ||
22 | - console.log('Code run in https://localhost:'+PORT); | ||
23 | -}); | ||
24 | - | ||
25 | - | ||
26 | - | ||
27 | - | ||
28 | - | ||
29 | - | ||
30 | - | ||
31 | - | ||
32 | -/* | ||
33 | -var express = require('express'); | ||
34 | -var app = express(); | ||
35 | -var bodyParser = require('body-parser'); | ||
36 | -var fs = require('fs'); | ||
37 | -const ejs = require('ejs'); | ||
38 | -var engines = require('consolidate'); | ||
39 | -const PORT = 80; | ||
40 | - | ||
41 | -// 크롤링 한 list 받아오기 | ||
42 | -const xports = require('./test1.js'); | ||
43 | -const zum = require('./test2.js'); | ||
44 | -const chosun = require('./test3.js'); | ||
45 | -const yna = require('./test4.js'); | ||
46 | - | ||
47 | -//console.log(xports.xports); | ||
48 | -//console.log(zum.zum); | ||
49 | -//console.log(chosun.chosun); | ||
50 | -//console.log(yna.yna); | ||
51 | - | ||
52 | -// router 설정 | ||
53 | -var indexRouter = require('./routes/index'); | ||
54 | - | ||
55 | -app.use(express.json()); | ||
56 | -app.use(express.urlencoded({extended:false})); | ||
57 | - | ||
58 | -app.use(express.static('public')) | ||
59 | - | ||
60 | -app.set('news', __dirname + '/news'); | ||
61 | -//화면 engine 설정 | ||
62 | -app.engine('html', engines.mustache); | ||
63 | -app.set('news engine', 'ejs'); | ||
64 | - | ||
65 | -// main 화면 | ||
66 | -app.use('/', indexRouter); | ||
67 | - | ||
68 | -// 서버 생성 | ||
69 | -app.listen(PORT, function(){ | ||
70 | - console.log('Code run in https://localhost:'+PORT); | ||
71 | -}); | ||
72 | -*/ |
testcode/views/index.css
deleted
100644 → 0
1 | -@charset "utf-8"; | ||
2 | -/************************************************* | ||
3 | -프로젝트명 : 연합뉴스 국문 모바일 홈페이지 (2019) | ||
4 | -commnet : default | ||
5 | -original : /global/guide/v01/css/default_v.0.2.css | ||
6 | -version : 0.2 | ||
7 | -modify : 2019-04-01 | ||
8 | -*************************************************/ | ||
9 | - | ||
10 | -html,body{width:100%;height:100%;margin:0;padding:0;} | ||
11 | -body{font-weight:normal;font-size:1em;line-height:1.5em;font-family:sans-serif;color:#000;-webkit-text-size-adjust:none;-ms-text-size-adjust:none;} | ||
12 | - | ||
13 | -h1,h2,h3,h4,h5,h6{margin:0;padding:0;font:inherit;font-weight:bold;} | ||
14 | -img{display:inline-block;border:0 none;vertical-align:top;} | ||
15 | -cite,code,dfn,del,em,ins,label,q,span,strong,b,i,time,mark,font,kbd,q,s,samp,small,strike,sub,sup,tt,var,u,center{display:inline-block;margin:0;padding:0;vertical-align:top;font:inherit;} | ||
16 | -address,cite,em,dfn{font:inherit;} | ||
17 | -b,i,strong,optgroup{font:inherit;font-weight:bold;} | ||
18 | - | ||
19 | -blockquote,p{margin:0;padding:0;font:inherit;} | ||
20 | -pre{overflow:auto;margin:0;padding:0;font:inherit;} | ||
21 | -mark{background:#fff;font:inherit;/* color:#000; */} /* IE 8/9 */ | ||
22 | -sub,sup{position:relative;font-size:0.75em;vertical-align:baseline;font:inherit;} | ||
23 | -abbr[title]{border-bottom:1px dotted;font:inherit;} | ||
24 | -hr{display:none;} | ||
25 | - | ||
26 | -div,article,aside,main,menu,details,figure,figcaption,hgroup,footer,header,nav,section,object,summary,iframe{display:block;margin:0;padding:0;font:inherit;} | ||
27 | -iframe{overflow:hidden;border:none;} | ||
28 | -audio,canvas,progress,video{display:inline-block;margin:0;padding:0;vertical-align:baseline;} | ||
29 | -audio:not([controls]){display:none;height:0;} | ||
30 | -[hidden],template{display:none;} | ||
31 | -svg:not(:root){overflow:hidden;} /* IE 9~11 */ | ||
32 | - | ||
33 | -/* table */ | ||
34 | -table{border-collapse:collapse;border-spacing:0;} | ||
35 | -caption{overflow:hidden;visibility:hidden;width:0;height:0;margin:0;padding:0;font-size:0;line-height:0;text-indent:-9999px;} | ||
36 | -th,td{margin:0;padding:0;font:inherit;text-align:left;vertical-align:middle;} | ||
37 | - | ||
38 | -/* list */ | ||
39 | -dl,dd,ol,ul,li{margin:0;padding:0;} | ||
40 | -li{list-style-type:none;} | ||
41 | - | ||
42 | -/* form */ | ||
43 | -form{margin:0;padding:0;} | ||
44 | -fieldset{margin:0;padding:0;border:0 none;} | ||
45 | -legend{overflow:hidden;visibility:hidden;position:absolute;top:0;left:0;width:0;height:0;margin:0;padding:0;font-size:0;line-height:0;} | ||
46 | -input,button,select,textarea{margin:0;padding:0;font:inherit;vertical-align:top;} | ||
47 | -input.text{padding:4px 7px 4px;border:1px solid #ccc;font-size:12px;line-height:1;color:#000;} | ||
48 | -input.readonly{background-color:#eee;} | ||
49 | -input.check,input.radio{width:13px;height:13px;margin:2px 7px 0 0;padding:0;} | ||
50 | -input[type="button"], | ||
51 | -input[type="reset"], | ||
52 | -input[type="submit"]{-webkit-appearance:button;cursor:pointer;} | ||
53 | -input[type="number"]::-webkit-inner-spin-button, | ||
54 | -input[type="number"]::-webkit-outer-spin-button{height:auto;} | ||
55 | -input[type="search"]{-webkit-appearance:textfield;box-sizing:content-box;} | ||
56 | -input[type="search"]::-webkit-search-cancel-button, | ||
57 | -input[type="search"]::-webkit-search-decoration{-webkit-appearance:none;} | ||
58 | -textarea{margin:0;padding:0;border:1px solid #ccc;font-size:12px;color:#000;resize:none;} | ||
59 | -select{height:20px;margin:0;border:1px solid #ccc;outline:none;background-color:#fff;font-size:12px;color:#000;vertical-align:top;text-transform:none;} | ||
60 | -button{overflow:visible;text-transform:none;cursor:pointer;} | ||
61 | -button::-moz-focus-inner, | ||
62 | -input::-moz-focus-inner{padding:0;border:0;} | ||
63 | -button[disabled],html input[disabled]{cursor:default;} | ||
64 | - | ||
65 | -/* link */ | ||
66 | -a{font:inherit;color:inherit;text-decoration:none;cursor:pointer;} | ||
67 | -a{background-color:transparent;} /* IE10 active transparent remove */ | ||
68 | -a:link, | ||
69 | -a:visited, | ||
70 | -a:active, | ||
71 | -a:focus{color:inherit;} | ||
72 | - | ||
73 | -/* selection */ | ||
74 | -/* PC 국문 개편에서는 설정 안 함 */ | ||
75 | -/* ::selection{opacity:0.1;background:#fff2a8;} | ||
76 | -::-moz-selection{background:#fff2a8;} */ | ||
77 | - | ||
78 | -/* skip navigation */ | ||
79 | -#skipNav{position:relative;z-index:800;} | ||
80 | -#skipNav a{overflow:hidden;position:absolute;width:1px;height:1px;margin-bottom:-1px;} | ||
81 | -#skipNav a:focus,#skipNav a:active{overflow:auto;display:block;position:absolute;width:100%;height:30px;margin:0;background-color:#fff000;font-weight:bold;font-size:14px;line-height:30px;color:#000;text-align:center;z-index:100;} | ||
82 | - | ||
83 | -/* clear */ | ||
84 | -.clear:after{content:".";visibility:hidden;display:block;clear:both;height:0;font-size:0;line-height:0;} | ||
85 | -.clear{display:inline-block;} | ||
86 | -*html .clear{height:0;} | ||
87 | -.clear{display:block;} | ||
88 | -.clear-both{clear:both;} | ||
89 | - | ||
90 | -/* basic */ | ||
91 | -.hidden-obj{position:absolute;visibility:hidden;top:-9999px;left:-9999px;} | ||
92 | -.blind{overflow:hidden;visibility:hidden;position:absolute;top:0;left:0;width:0;height:0;padding:0;font-size:0;line-height:0;} | ||
93 | -.display-none{display:none;} | ||
94 | -.for-mobile{display:none} | ||
95 | -.visible-hidden{visibility:hidden;} | ||
96 | -.word-break{word-break:break-all !important;} | ||
97 | -.text-indent{overflow:hidden;display:block;text-indent:-9999px;} | ||
98 | -.text-c{text-align:center !important;} | ||
99 | -.text-l{text-align:left !important;} | ||
100 | -.text-r{text-align:right !important;} | ||
101 | -.vt-t{vertical-align:top !important;} | ||
102 | -.vt-m{vertical-align:middle !important;} | ||
103 | -.vt-b{vertical-align:bottom !important;} | ||
104 | -.fw-b{font-weight:bold !important;} | ||
105 | -.fw-n{font-weight:normal !important;} | ||
106 | -.fl-l{float:left;} | ||
107 | -.fl-r{float:right;} | ||
108 | -.fn{float:none !important;} | ||
109 | -.bg-none{background:none !important;} | ||
110 | -.bd-n{border:none !important;} | ||
111 | -.bd-t{border-top:none !important;} | ||
112 | -.bd-r{border-right:none !important;} | ||
113 | -.bd-b{border-bottom:none !important;} | ||
114 | -.bd-l{border-left:none !important;} | ||
115 | -.of-a{overflow:auto;} | ||
116 | -.of-h{overflow:hidden;} | ||
117 | -.scroll-x{overflow-x:scroll;} | ||
118 | -.scroll-y{overflow-y:scroll;} | ||
119 | -.mg-none{margin:0 !important;} | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
... | @@ -19,84 +19,22 @@ | ... | @@ -19,84 +19,22 @@ |
19 | </div> | 19 | </div> |
20 | <section class = 'box-type box-latest01'> | 20 | <section class = 'box-type box-latest01'> |
21 | <strong class="hidden-obj">야구 기사 목록</strong> | 21 | <strong class="hidden-obj">야구 기사 목록</strong> |
22 | + <div class = "paging paging-type01"> | ||
23 | + <strong class = "num on">All</strong> | ||
24 | + <a href="/nc" class="num">NC</a> | ||
25 | + <a href="/lg" class="num">LG</a> | ||
26 | + <a href="/doosan" class="num">두산</a> | ||
27 | + <a href="/kiwoom" class="num">키움</a> | ||
28 | + <a href="/kia" class="num">KIA</a> | ||
29 | + <a href="/lotte" class="num">롯데</a> | ||
30 | + <a href="/samsung" class="num">삼성</a> | ||
31 | + <a href="/kt" class="num">KT</a> | ||
32 | + <a href="/sk" class="num">SK</a> | ||
33 | + <a href="/hanwha" class="num">한화</a> | ||
34 | + </div> | ||
22 | <div class = "list-type038"> | 35 | <div class = "list-type038"> |
23 | <ul class = "list"> | 36 | <ul class = "list"> |
24 | - <% for(var i of xports) { %> | 37 | + <% for(var i of newslist) { %> |
25 | - <li> | ||
26 | - <div class='item-box01'> | ||
27 | - <div class='info-box01'> | ||
28 | - <span class="blind">송고시간</span> | ||
29 | - <span class='txt-time'><%= i.datetime %></span> | ||
30 | - </div> | ||
31 | - <% if (i.image_url != undefined) { %> | ||
32 | - <figure class='img-con'> | ||
33 | - <a class = "img img-cover imgLiquid_bgSize imgLiquid_ready" style = "background-size: cover; background-position: center top; background-repeat: no-repeat;" href = <%= i.url %> > | ||
34 | - <img src = <%= i.image_url %>> | ||
35 | - </a> | ||
36 | - </figure> | ||
37 | - <% } %> | ||
38 | - <div class='news-con'> | ||
39 | - <a class = 'tit-wrap' href = <%= i.url %>> | ||
40 | - <strong class = 'tit-news'><%= i.title %></strong> | ||
41 | - </a> | ||
42 | - <p class = "lead"> | ||
43 | - <%= i.summary %> | ||
44 | - </p> | ||
45 | - </div> | ||
46 | - </div> | ||
47 | - </li> | ||
48 | - <% } %> | ||
49 | - <% for(var i of zum) { %> | ||
50 | - <li> | ||
51 | - <div class='item-box01'> | ||
52 | - <div class='info-box01'> | ||
53 | - <span class="blind">송고시간</span> | ||
54 | - <span class='txt-time'><%= i.datetime %></span> | ||
55 | - </div> | ||
56 | - <% if (i.image_url != undefined) { %> | ||
57 | - <figure class='img-con'> | ||
58 | - <a class = "img img-cover imgLiquid_bgSize imgLiquid_ready" style = "background-size: cover; background-position: center top; background-repeat: no-repeat;" href = <%= i.url %> > | ||
59 | - <img src = <%= i.image_url %>> | ||
60 | - </a> | ||
61 | - </figure> | ||
62 | - <% } %> | ||
63 | - <div class='news-con'> | ||
64 | - <a class = 'tit-wrap' href = <%= i.url %>> | ||
65 | - <strong class = 'tit-news'><%= i.title %></strong> | ||
66 | - </a> | ||
67 | - <p class = "lead"> | ||
68 | - <%= i.summary %> | ||
69 | - </p> | ||
70 | - </div> | ||
71 | - </div> | ||
72 | - </li> | ||
73 | - <% } %> | ||
74 | - <% for(var i of chosun) { %> | ||
75 | - <li> | ||
76 | - <div class='item-box01'> | ||
77 | - <div class='info-box01'> | ||
78 | - <span class="blind">송고시간</span> | ||
79 | - <span class='txt-time'><%= i.datetime %></span> | ||
80 | - </div> | ||
81 | - <% if (i.image_url != undefined) { %> | ||
82 | - <figure class='img-con'> | ||
83 | - <a class = "img img-cover imgLiquid_bgSize imgLiquid_ready" style = "background-size: cover; background-position: center top; background-repeat: no-repeat;" href = <%= i.url %> > | ||
84 | - <img src = <%= i.image_url %>> | ||
85 | - </a> | ||
86 | - </figure> | ||
87 | - <% } %> | ||
88 | - <div class='news-con'> | ||
89 | - <a class = 'tit-wrap' href = <%= i.url %>> | ||
90 | - <strong class = 'tit-news'><%= i.title %></strong> | ||
91 | - </a> | ||
92 | - <p class = "lead"> | ||
93 | - <%= i.summary %> | ||
94 | - </p> | ||
95 | - </div> | ||
96 | - </div> | ||
97 | - </li> | ||
98 | - <% } %> | ||
99 | - <% for(var i of yna) { %> | ||
100 | <li> | 38 | <li> |
101 | <div class='item-box01'> | 39 | <div class='item-box01'> |
102 | <div class='info-box01'> | 40 | <div class='info-box01'> | ... | ... |
testcode/views/nc.ejs
0 → 100644
1 | +<!DOCTYPE html> | ||
2 | +<html> | ||
3 | + | ||
4 | + <head> | ||
5 | + <meta charset="utf-8"> | ||
6 | + <link rel="stylesheet" href="/stylesheets/style.css" /> | ||
7 | + <title>YaguMoa[ossswoo.tk]</title> | ||
8 | + </head> | ||
9 | + | ||
10 | + <body class = "body-news-list page-sports body-static" data-nav="sports"> | ||
11 | + <div id = "container" class = "wrap-container"> | ||
12 | + <div class = "container"> | ||
13 | + <div class = 'content03 width1100 line01'> | ||
14 | + <div class = "section01"> | ||
15 | + <div class = 'title-page02'> | ||
16 | + <h1 class = "title-type04 bold"> | ||
17 | + <span class = "tit">야구 모아</span> | ||
18 | + </h1> | ||
19 | + </div> | ||
20 | + <section class = 'box-type box-latest01'> | ||
21 | + <strong class="hidden-obj">NC 목록</strong> | ||
22 | + <div class = "paging paging-type01"> | ||
23 | + <a href="/" class="num">All</a> | ||
24 | + <strong class = "num on">NC</strong> | ||
25 | + <a href="/lg" class="num">LG</a> | ||
26 | + <a href="/doosan" class="num">두산</a> | ||
27 | + <a href="/kiwoom" class="num">키움</a> | ||
28 | + <a href="/kia" class="num">KIA</a> | ||
29 | + <a href="/lotte" class="num">롯데</a> | ||
30 | + <a href="/samsung" class="num">삼성</a> | ||
31 | + <a href="/kt" class="num">KT</a> | ||
32 | + <a href="/sk" class="num">SK</a> | ||
33 | + <a href="/hanwha" class="num">한화</a> | ||
34 | + </div> | ||
35 | + <div class = "list-type038"> | ||
36 | + <ul class = "list"> | ||
37 | + <% for(var i of nc) { %> | ||
38 | + <li> | ||
39 | + <div class='item-box01'> | ||
40 | + <div class='info-box01'> | ||
41 | + <span class="blind">송고시간</span> | ||
42 | + <span class='txt-time'><%= i.datetime %></span> | ||
43 | + </div> | ||
44 | + <% if (i.image_url != undefined) { %> | ||
45 | + <figure class='img-con'> | ||
46 | + <a class = "img img-cover imgLiquid_bgSize imgLiquid_ready" style = "background-size: cover; background-position: center top; background-repeat: no-repeat;" href = <%= i.url %> > | ||
47 | + <img src = <%= i.image_url %>> | ||
48 | + </a> | ||
49 | + </figure> | ||
50 | + <% } %> | ||
51 | + <div class='news-con'> | ||
52 | + <a class = 'tit-wrap' href = <%= i.url %>> | ||
53 | + <strong class = 'tit-news'><%= i.title %></strong> | ||
54 | + </a> | ||
55 | + <p class = "lead"> | ||
56 | + <%= i.summary %> | ||
57 | + </p> | ||
58 | + </div> | ||
59 | + </div> | ||
60 | + </li> | ||
61 | + <% } %> | ||
62 | + </ul> | ||
63 | + </div> | ||
64 | + </section> | ||
65 | + </div> | ||
66 | + </div> | ||
67 | + </div> | ||
68 | + </div> | ||
69 | + </body> | ||
70 | +</html> |
File moved
... | @@ -12,7 +12,7 @@ const getHtml = async () => { | ... | @@ -12,7 +12,7 @@ const getHtml = async () => { |
12 | }; | 12 | }; |
13 | 13 | ||
14 | 14 | ||
15 | -const getXports = async () => { | 15 | +const getYna = async () => { |
16 | 16 | ||
17 | return new Promise((resolve, reject) => { | 17 | return new Promise((resolve, reject) => { |
18 | getHtml() | 18 | getHtml() |
... | @@ -42,4 +42,4 @@ const getXports = async () => { | ... | @@ -42,4 +42,4 @@ const getXports = async () => { |
42 | }); | 42 | }); |
43 | }; | 43 | }; |
44 | 44 | ||
45 | -module.exports = getXports; | 45 | +module.exports = getYna; | ... | ... |
... | @@ -12,7 +12,7 @@ const getHtml = async () => { | ... | @@ -12,7 +12,7 @@ const getHtml = async () => { |
12 | }; | 12 | }; |
13 | 13 | ||
14 | 14 | ||
15 | -const getXports = async () => { | 15 | +const getZum = async () => { |
16 | 16 | ||
17 | return new Promise((resolve, reject) => { | 17 | return new Promise((resolve, reject) => { |
18 | getHtml() | 18 | getHtml() |
... | @@ -42,4 +42,4 @@ const getXports = async () => { | ... | @@ -42,4 +42,4 @@ const getXports = async () => { |
42 | }); | 42 | }); |
43 | }; | 43 | }; |
44 | 44 | ||
45 | -module.exports = getXports; | 45 | +module.exports = getZum; | ... | ... |
-
Please register or login to post a comment