This commit is contained in:
37
index.html
37
index.html
@@ -11,16 +11,45 @@
|
||||
<body id="index">
|
||||
<header>{include file="public/header"}</header>
|
||||
|
||||
<!-- banner(恢复 Swiper 轮播结构,数据由 $data.banner 提供;未配置时使用静态占位) -->
|
||||
<!-- banner(Swiper 轮播,数据由 $data.banner 提供;未配置时使用静态占位) -->
|
||||
<section class="section banner">
|
||||
<div class="swiper banner-cont">
|
||||
<div class="swiper-wrapper">
|
||||
{if ( isset($data.banner) ) }
|
||||
{foreach $data.banner as $key=>$value}
|
||||
<div class="swiper-slide">
|
||||
<a href="{$value.url|default='javascript:;'}">
|
||||
<img class="img-responsive img center-block" src="{$value.img}" alt="">
|
||||
</a>
|
||||
<img class="img-responsive img center-block" src="{$value.img|default='/web/BlackFruit-web/assets/img/index/1@2x.png'}" alt="">
|
||||
<div class="section-content">
|
||||
{if !empty($value.tags)}
|
||||
{php}$__tags = preg_split('/[,,]/', $value['tags']);{/php}
|
||||
<div class="banner-tags">
|
||||
{foreach $__tags as $__t}
|
||||
{php}$__t_trim = trim($__t);{/php}
|
||||
{if $__t_trim != ''}
|
||||
<span class="banner-tag-pill">{$__t_trim}</span>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{if !empty($value.title)}
|
||||
<h1>{$value.title}</h1>
|
||||
{/if}
|
||||
|
||||
{if !empty($value.description)}
|
||||
<p class="banner-desc">{$value.description}</p>
|
||||
{/if}
|
||||
|
||||
{if !empty($value.button_text)}
|
||||
<a
|
||||
class="btn btn2 btn-normal"
|
||||
href="{$value.button_link|default=$value.url|default='javascript:;'}"
|
||||
{if !empty($value.button_blank) || !empty($value.blank)}target="_blank"{/if}
|
||||
>
|
||||
{$value.button_text}
|
||||
</a>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
{else /}
|
||||
|
||||
Reference in New Issue
Block a user