@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
defined('IN_TS') or die('Access Denied.');
|
||||
return array(
|
||||
'hook'=>'home_index_left', //钩子
|
||||
'name' => '推荐小组',
|
||||
'version' => '1.0',
|
||||
'desc' => '推荐小组',
|
||||
'url' => 'http://www.thinksaas.cn',
|
||||
'email' => 'thinksaas@qq.com',
|
||||
'author' => '邱君',
|
||||
'author_url' => 'http://www.thinksaas.cn',
|
||||
'isedit' => '0',
|
||||
);
|
||||
@@ -0,0 +1,28 @@
|
||||
<div class="card">
|
||||
<div class="card-header">推荐小组</div>
|
||||
<div class="card-body">
|
||||
{if $arrRecommendGroup}
|
||||
<div class="row">
|
||||
{loop $arrRecommendGroup $key $item}
|
||||
<div class="col-md-6">
|
||||
<div class="sub-item">
|
||||
<div class="pic">
|
||||
<a href="{tsUrl('group','show',array('id'=>$item['groupid']))}">
|
||||
<img class="rounded" src="{$item['photo']}" alt="{$item['groupname']}" title="{$item['groupname']}" />
|
||||
</a>
|
||||
</div>
|
||||
<div class="info">
|
||||
<a class="font-weight-bold" href="{tsUrl('group','show',array('id'=>$item['groupid']))}">{$item['groupname']}</a> <span class="fs12 c9">{$item['count_user']} 成员</span>
|
||||
<div class="content">{php echo cututf8(t($item['groupdesc']),0,43,false)}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/loop}
|
||||
</div>
|
||||
{else}
|
||||
|
||||
<div class="c9">暂无推荐小组</div>
|
||||
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?php
|
||||
defined('IN_TS') or die('Access Denied.');
|
||||
//推荐小组
|
||||
function recommendgroup(){
|
||||
$arrRecommendGroup = aac('group')->getRecommendGroup('12');
|
||||
include template('recommendgroup','recommendgroup');
|
||||
}
|
||||
function recommendgroup_css(){
|
||||
echo '<link href="'.SITE_URL.'plugins/home/recommendgroup/style.css" rel="stylesheet" type="text/css" />';
|
||||
}
|
||||
addAction('home_index_left','recommendgroup');
|
||||
addAction('pub_header_top','recommendgroup_css');
|
||||
@@ -0,0 +1,26 @@
|
||||
.sub-item{
|
||||
border-bottom: 1px dashed #AAAAAA;
|
||||
height: 72px;
|
||||
margin: 0 2px 15px 0;
|
||||
overflow: hidden;
|
||||
}
|
||||
.sub-item .pic {
|
||||
float: left;
|
||||
width: 48px;
|
||||
}
|
||||
.sub-item .info {
|
||||
color: #666666;
|
||||
vertical-align: top;
|
||||
word-wrap: break-word;
|
||||
margin-left:60px;
|
||||
}
|
||||
.sub-item .pic img {
|
||||
height: 48px;
|
||||
margin-bottom: -3px;
|
||||
width: 48px;
|
||||
}
|
||||
.sub-item .info .content{font-size:12px;}
|
||||
|
||||
.sub-item p {
|
||||
margin: 0;
|
||||
}
|
||||
Reference in New Issue
Block a user