article.html 2.7 KB
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
    <title>文章详情</title>
    <script src="__TMPL__/public/assets/js/fontsize.js"></script>
    <link rel="stylesheet" href="__TMPL__/public/assets/css/init.css">
    <link rel="stylesheet" href="__TMPL__/public/assets/css/swiper-3.4.2.min.css">
    <link rel="stylesheet" href="http://at.alicdn.com/t/font_793738_tlxymah92x.css">
    <link rel="stylesheet" href="__TMPL__/public/assets/css/ChatCircle.css">
    <link rel="stylesheet" href="__TMPL__/public/assets/css/comment.css">
</head>
<body style="background: #F5FAF7">

<!--内容部分-->
<div class="article_box">
    <div class="article_item">
        <div class="article_title">{$article.post_title}</div>
        <div class="article_info">
            <text>{$article.user.user_login}</text>
            <text>{:date('Y.m.d',$article.published_time)}</text>
        </div>
        <div>
         {$article.post_content}
        </div>
    </div>
          <php>
                        $after_content_hook_param=[
                        'object_id'=>$article['id'],
                        'table_name'=>'portal_post',
                        'object_title'=>$article['post_title'],
                        'user_id'=>$article['user_id'],
                        'url'=>cmf_url_encode('portal/Article/index',array('id'=>$article['id'],'cid'=>$category['id'])),
                        'object'=>$article
                        ];
                    </php>
          <hook name="after_content" param="after_content_hook_param"/>
           <php>
                          $comment_hook_param=[
                          'object_id'=>$article['id'],
                          'table_name'=>'portal_post',
                          'full_name'=>'portal_post',
                          'object_title'=>$article['post_title'],
                          'url'=>cmf_url_encode('portal/Article/index',array('id'=>$article['id'],'cid'=>$category['id']))
                          ];
                          $comment=hook_one('comment',$comment_hook_param);
                      </php>

                      <if condition="empty($comment) && cmf_get_current_admin_id()">
                          <div style="border: 1px dashed #ddd;min-height: 200px;padding-top: 50px;">
                              <div class="alert alert-warning" role="alert">
                                  此区域这为评论区,请安装评论插件!<br>
                                  <em>注:普通用户不会看到此提示!</em>
                              </div>
                          </div>
                      </if>
        {$comment}

</body>
</html>