公告
  
重要通知:网站网络变更中,防失联!请及时查看本消息!
更多资讯请关注公众号“鸿盟创客”
点击查看消息详情!

朕已阅

白色简约(手机模板)

admin 千秋月 关注 管理组 论坛神话
发表于插件模板版块 模板
白色简约(手机模板)

演示地址请访问演示站公告

演示站公告直达:进入


以下导航代码复制粘贴在后台 - 模板 - 白色简约 - 导航HTML处,链接、图标及文字自行更改。






导航默认样式:


<div class="pk-row">

<div class="pk-w-sm-3" style="border-right:solid 1px #EFEFEF;">

<a href="#"><span class="fa fa-list"></span><br>导航</a>

</div>

<div class="pk-w-sm-3" style="border-right:solid 1px #EFEFEF;">

<a href="#"><span class="fa fa-delicious"></span><br>导航</a>

</div>

<div class="pk-w-sm-3" style="border-right:solid 1px #EFEFEF;">

<a href="#"><span class="fa fa-download"></span><br>导航</a>

</div>

<div class="pk-w-sm-3">

<a href="#"><span class="fa fa-shopping-cart"></span><br>导航</a>

</div>

</div>

手机可滑动的多导航样式:


<script src="/template/puyuetian_baisejianyue/js/swipe.min.js"></script>

<style>

.swipe {

overflow: hidden;

visibility: hidden;

position: relative;

}

.swipe>div:nth-of-type(2) {

padding: 10px 0 5px;

}

.swipe>div:nth-of-type(2)>span {

display: inline-block;

width: 8px;

height: 8px;

border-radius: 50%;

border: solid 1px #777;

margin-right: 4px;

}

.swipe-wrap {

overflow: hidden;

position: relative;

}

.swipe-wrap>div {

float: left;

width: 100%;

position: relative;

}

.swipe-wrap>div>div>div {

padding-top: 15px;

text-align: center;

}

.swipe-wrap>div>div>div>a {

display: block;

margin: 0 auto;

width: 56px;

}

.swipe-wrap>div>div>div>a>span:nth-of-type(1) {

float: left;

border-radius: 50%;

font-size: 28px;

background-color: #12b7f5;

color: #fff;

width: 56px;

height: 56px;

line-height: 56px;

margin-bottom: 5px;

}

.swipe-wrap>div>div>div>a>span:nth-of-type(2) {

font-size: 16px;

color: #555;

word-break: keep-all;

overflow: hidden;

}

</style>

<div id='slider' class='swipe'>

<div class='swipe-wrap'>

<div>

<div class="pk-row">

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-home"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-list-ul"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-th"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-shopping-cart"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-download"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-plug"></span>

<span>导航</span>

</a>

</div>

</div>

</div>

<div>

<div class="pk-row">

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-home"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-list-ul"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-th"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-shopping-cart"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-download"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-plug"></span>

<span>导航</span>

</a>

</div>

</div>

</div>

<div>

<div class="pk-row">

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-home"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-list-ul"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-th"></span>

<span>导航</span>

</a>

</div>

<div class="pk-w-sm-4">

<a href="#">

<span class="fa fa-fw fa-shopping-cart"></span>

<span>导航</span>

</a>

</div>

</div>

</div>

</div>

<div></div>

</div>

<script>

//导航链接的处理,添加定位控制参数

$('#slider .swipe-wrap>div a').each(function() {

var h2;

$(this).attr('href').indexOf('?') == -1 ? h2 = '?' : h2 = '&';

$(this).attr('href', $(this).attr('href') + h2 + 'swipe_div_index=' + $(this).parent().parent().parent().index() + '&swipe_a_index=' + $(this).parent().index());

});

//添加下面的小灰点

$('#slider .swipe-wrap>div').each(function() {

$('#slider>div:eq(1)').append('<span></span>');

});

//跳至并选中导航链接

var swipe_div_index = $_GET('swipe_div_index') || 0;

var swipe_a_index = $_GET('swipe_a_index') || -1;

if(swipe_a_index > -1) {

$('#slider .swipe-wrap>div:eq(' + swipe_div_index + ') a:eq(' + swipe_a_index + ')').css('opacity', 0.2).attr('href', 'javascript:');

}

$('#slider>div:eq(1)>span:eq(' + swipe_div_index + ')').css('background-color', '#777');

window.mySwipe = Swipe($('#slider')[0], {

startSlide: swipe_div_index,

callback: function(index, elem) {

$('#slider>div:eq(1)>span').css('background-color', '#FFF');

$('#slider>div:eq(1)>span:eq(' + index + ')').css('background-color', '#777');

}

});

</script>



导航图标库:http://fontawesome.io/icons/

评论列表 评论
发布评论

评论: 白色简约(手机模板)



点击进入免费吃瓜群!吃大瓜! 广告位支持代码、文字、图片展示 Image


免责声明
本站资源,均来自网络,版权归原作者,所有资源和文章仅限用于学习和研究目的 。 不得用于商业或非法用途,否则,一切责任由该用户承担 !

请求资源或报告无效资源,请点击[反馈中心]


侵权删除请致信 E-Mail:chengfengad@gmail.com
已有0次打赏
(0) 分享
分享
取消