diff --git a/assets/radar-rules.js b/assets/radar-rules.js
index d50fba6347..064583cfb2 100644
--- a/assets/radar-rules.js
+++ b/assets/radar-rules.js
@@ -830,4 +830,16 @@
},
],
},
+
+ 'chinatimes.com': {
+ _name: '中時電子報',
+ www: [
+ {
+ title: '新聞',
+ docs: 'https://docs.rsshub.app/traditional-media.html#zhong-shi-dian-zi-bao',
+ source: '/:caty',
+ target: (params) => '/chinatimes/' + params.caty,
+ },
+ ],
+ },
});
diff --git a/docs/en/traditional-media.md b/docs/en/traditional-media.md
index 7f689d0b78..8ac49d8896 100644
--- a/docs/en/traditional-media.md
+++ b/docs/en/traditional-media.md
@@ -20,6 +20,18 @@ Support major channels, refer to [BBC RSS feeds](https://www.bbc.co.uk/news/1062
+## China Times
+
+### News
+
+
+
+| realtimenews | politic | opinion | life | star | money | society | hottopic | tube | world | armament | chinese | fashion | sports | technologynews | travel | album |
+| -------------- | ------- | ------- | ---- | ------- | ------- | ------- | ---------- | ------ | ----- | -------- | ----------------- | ------- | ------ | --------------- | ------ | ------- |
+| Real Time News | Politic | Opinion | Life | Showbiz | Finance | Society | Hot Topics | Videos | World | Military | Mainland & Taiwan | Fashion | Sports | Technology News | Travel | Columns |
+
+
+
## The Guardian
### Editorial
diff --git a/docs/traditional-media.md b/docs/traditional-media.md
index e91dc64f45..33075862c4 100644
--- a/docs/traditional-media.md
+++ b/docs/traditional-media.md
@@ -448,3 +448,15 @@ category 对应的关键词有
| thelatest | news_bilingual | news_hotwords | practice_tongue | trans_collect | video_links | audio_cd | columnist | 5af95d44a3103f6866ee845c | englishexams |
+
+## 中時電子報
+
+### 新聞
+
+
+
+| realtimenews | politic | opinion | life | star | money | society | hottopic | tube | world | armament | chinese | fashion | sports | technologynews | travel | album |
+| ------------ | ------- | ------- | ---- | ---- | ----- | ------- | -------- | ------- | ----- | -------- | ------- | ------- | ------ | -------------- | ------ | ----- |
+| 即時 | 政治 | 言論 | 生活 | 娛樂 | 財經 | 社會 | 話題 | 快點 TV | 國際 | 軍事 | 兩岸 | 時尚 | 體育 | 科技 | 玩食 | 專輯 |
+
+
diff --git a/lib/router.js b/lib/router.js
index ade5c9836c..21694c4754 100644
--- a/lib/router.js
+++ b/lib/router.js
@@ -1995,6 +1995,9 @@ router.get('/itslide/new', require('./routes/itslide/new'));
// Remote Work
router.get('/remote-work/:caty?', require('./routes/remote-work/index'));
+// China Times
+router.get('/chinatimes/:caty', require('./routes/chinatimes/index'));
+
// TransferWise
router.get('/transferwise/pair/:source/:target', require('./routes/transferwise/pair'));
diff --git a/lib/routes/chinatimes/index.js b/lib/routes/chinatimes/index.js
new file mode 100644
index 0000000000..6565e19e16
--- /dev/null
+++ b/lib/routes/chinatimes/index.js
@@ -0,0 +1,115 @@
+const url = require('url');
+const got = require('@/utils/got');
+const cheerio = require('cheerio');
+
+const root_url = 'https://www.chinatimes.com';
+
+const config = {
+ realtimenews: {
+ link: '/realtimenews/?chdtv',
+ title: 'China Times - Real Time News',
+ },
+ politic: {
+ link: '/politic/?chdtv',
+ title: 'China Times - Politic',
+ },
+ opinion: {
+ link: '/opinion/?chdtv',
+ title: 'China Times - Opinion',
+ },
+ life: {
+ link: '/life/?chdtv',
+ title: 'China Times - Life',
+ },
+ star: {
+ link: '/star/?chdtv',
+ title: 'China Times - Showbiz',
+ },
+ money: {
+ link: '/money/?chdtv',
+ title: 'China Times - Finance',
+ },
+ society: {
+ link: '/society/?chdtv',
+ title: 'China Times - Society',
+ },
+ hottopic: {
+ link: '/hottopic/?chdtv',
+ title: 'China Times - Hot Topics',
+ },
+ tube: {
+ link: '/tube/?chdtv',
+ title: 'China Times - Videos',
+ },
+ world: {
+ link: '/world/?chdtv',
+ title: 'China Times - World',
+ },
+ armament: {
+ link: '/armament/?chdtv',
+ title: 'China Times - Military',
+ },
+ chinese: {
+ link: '/chinese/?chdtv',
+ title: 'China Times - Mainland & Taiwan',
+ },
+ fashion: {
+ link: '/fashion/?chdtv',
+ title: 'China Times - Fashion',
+ },
+ sports: {
+ link: '/sports/?chdtv',
+ title: 'China Times - Sports',
+ },
+ technologynews: {
+ link: '/technologynews/?chdtv',
+ title: 'China Times - Technology News',
+ },
+ travel: {
+ link: '/travel/?chdtv',
+ title: 'China Times - Travel',
+ },
+ album: {
+ link: '/album/?chdtv',
+ title: 'China Times - Columns',
+ },
+};
+
+module.exports = async (ctx) => {
+ const cfg = config[ctx.params.caty];
+ if (!cfg) {
+ throw Error('Bad category. See https://docs.rsshub.app/traditional-media.html#zhong-shi-dian-zi-bao');
+ }
+
+ const current_url = url.resolve(root_url, cfg.link);
+ const response = await got({
+ method: 'get',
+ url: current_url,
+ });
+
+ const $ = cheerio.load(response.data);
+ const list = $('section.article-list ul div.row')
+ .map((_, item) => {
+ item = $(item);
+ const right = item.find('div.col');
+ const a = right.find('h3.title a');
+ const img = item.find('img.photo').attr('src');
+ let desc = '
' + right.find('p.intro').text() + '...
';
+ if (img) {
+ desc = `
` + desc;
+ }
+ return {
+ title: a.text(),
+ link: a.attr('href'),
+ pubDate: new Date(right.find('div.meta-info time').attr('datetime') + ' GMT+8').toUTCString(),
+ description: desc,
+ };
+ })
+ .get();
+
+ ctx.state.data = {
+ title: cfg.title,
+ link: current_url,
+ item: list,
+ };
+};