diff --git a/config/define.php b/config/define.php index 46087ff..2a9004a 100644 --- a/config/define.php +++ b/config/define.php @@ -51,6 +51,8 @@ define('WEIBO_LOGIN_COOKIE', '_2A25FItemDeRhGeFH41MV8ibNyjSIHXVmXlVurDV8PUNbmtAYLWP9kW9NekLV22FUUuTM0k2WTJS1xyONMvh_V90k'); + define('WEIBO_DETAIL_URL', 'https://zhishiku.yizherenxin.cn/weibo/show_detail/wid/%s'); + define('WEIBO_USER_ZHANG',2282201403); define('WEIBO_USER_XU',1285478591); define('WEIBO_USER_CHENG',5031299688); diff --git a/control/weibo.php b/control/weibo.php index 376b851..99624b9 100644 --- a/control/weibo.php +++ b/control/weibo.php @@ -106,4 +106,8 @@ class weibo extends publicBase { $this->ajax_json(true, '获取成功', $rdata); } + + public function show_detail() { + $this->view['wid'] = $this->get('wid') + 0; + } } diff --git a/model/mWeiboBehavior.php b/model/mWeiboBehavior.php index c47246a..c183e1c 100644 --- a/model/mWeiboBehavior.php +++ b/model/mWeiboBehavior.php @@ -71,6 +71,7 @@ class mWeiboBehavior extends mBase { $re['uname'] = empty($weibo)? $weibo_user[WEIBO_USER_ZHANG] : $weibo_user[$weibo['uid']]; $re['title'] = empty($weibo)? '无文字展示' : $weibo['text']; + $re['url'] = sprintf(WEIBO_DETAIL_URL, $re['wid']); } return $res; } diff --git a/view/templates/weibo/show_detail.html b/view/templates/weibo/show_detail.html new file mode 100644 index 0000000..23898b3 --- /dev/null +++ b/view/templates/weibo/show_detail.html @@ -0,0 +1,30 @@ + + + + + + + + 详情 + {literal} + + {/literal} + + + + + + + \ No newline at end of file