home.html
3.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
{template 'common/header'}
{template 'common/slide'}
<style>
body{
font:{$_W['styles']['fontsize']} {$_W['styles']['fontfamily']};
color:{$_W['styles']['fontcolor']};
padding:0;
margin:0;
background-image:url('{if !empty($_W['styles']['indexbgimg'])}{$_W['styles']['indexbgimg']}{/if}');
background-size:cover;
background-color:{if empty($_W['styles']['indexbgcolor'])}#000{else}{$_W['styles']['indexbgcolor']}{/if};
{$_W['styles']['indexbgextra']}
}
a{color:{$_W['styles']['linkcolor']}; text-decoration:none;}
{$_W['styles']['css']}
.box{width:100%;overflow:hidden;}
.box .box-item{float:left; text-align:center; display:block; text-decoration:none; outline:none; width:{php echo (100/3).'%';}; height:90px; position:relative; color:#FFF; background:#333; padding:5px 10px; overflow:hidden;}
.box-item.black{background-image: -moz-linear-gradient(top, #606060, #282828); background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#606060), to(#282828)); background-image: -webkit-linear-gradient(top, #606060, #282828); background-image: -o-linear-gradient(top, #606060, #282828); background-image: linear-gradient(to bottom, #606060, #282828); background-repeat: repeat-x;}
.box-item.blue{background-image: -moz-linear-gradient(top, #8ea5c2, #2f5d94); background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#8ea5c2), to(#2f5d94)); background-image: -webkit-linear-gradient(top, #8ea5c2, #2f5d94); background-image: -o-linear-gradient(top, #8ea5c2, #2f5d94); background-image: linear-gradient(to bottom, #8ea5c2, #2f5d94); background-repeat: repeat-x;}
.box .box-item i{display:inline-block; width:50px; height:50px; line-height:50px; font-size:35px; color:#FFF; overflow:hidden;}
.box .box-item span{color:{$_W['styles']['fontnavcolor']};display:block;font-size:14px; width:90%; height:20px; line-height:20px; margin:0 5%; text-align:center; overflow:hidden;}
.box ul li{background-color:#333;padding:0 10px;margin:1%;display: inline-block;height:45px;width:100%;}
.box ul li a{text-decoration: none;}
.box .title{color:#fff;}
.box .createtime{color:#999;font-size:12px}
.footer{color:#FFF;}
</style>
<div class="box clearfix">
{php $num = 1;}
{loop $navs $nav}
<a href="{$nav['url']}" class="box-item {if $num%2}black{else}blue{/if}">
{if !empty($nav['icon'])}
<i style="background:url({$_W['attachurl']}{$nav['icon']}) no-repeat;background-size:cover;" class=""></i>
{else}
<i class="fa {$nav['css']['icon']['icon']}" style="{$nav['css']['icon']['style']}"></i>
{/if}
<span style="{$nav['css']['name']}" title="{$nav['name']}">{$nav['name']}</span>
</a>
{php $num++;}
{/loop}
<!-- 该分类下文章-start -->
{if $_GPC['c'] == 'site' && $_GPC['a'] == 'site'}
<ul class="list list-unstyled">
{data func="site_article" cid=$cid return="true" assign="result"}
{loop $result['list'] $row}
<li>
<a href="{$row['linkurl']}">
<div class="title">{php echo cutstr($row['title'],20,1);}</div>
<div class="createtime">{php echo date('Y-m-d H:i:s', $row['createtime'])}</div>
</a>
</li>
{/loop}
</ul>
{/if}
<!-- 该分类下文章-start -->
</div>
{template 'common/footer'}