【建站问答】Discuz论坛网站添加一些轮播图模块教程

我们经常在别的DISCUZ论坛网站上会看见有一些高端大气的轮播图,有些小伙伴非常的羡慕,因此也想在自己的网站上个添加一些轮播图模块,那么如何实现呢?下面迦洛SEO介绍一下DISCUZ论坛网站轮播图制作方法。

【建站问答】Discuz论坛网站添加一些轮播图模块教程

1、下载js文件,解压放在images文件下:
https://pan.baidu.com/s/1bnnuTtl
2、在需要显示换灯片的位置,删除原有的代码,放入DIY代码:

<div class=”i-focus” id=”iFocus”>
<div id=”diyflash9″ class=”area”></div>
</div>

3、在调用底部文件的代码上方放上以下的JS代码来调用JS文件

<script src=”template/awx/images/js/jquery1.8.3.js” type=”text/javascript”></script>
<script src=”template/awx/images/js/focusfade.js” type=”text/javascript”></script>
<script src=”template/awx/images/js/index.js” type=”text/javascript”></script>

4、在DIY中放入以下的代码【可以根据自己需要设置数量】

<div class=”focus-pic”>
<div class=”if-inner”>
<ul>
[index=1]
<li style=”background:url(https://www.banban.so/new/20150912.jpg) no-repeat center;”>
<div class=”w1240″>
<a href=”{url}” target=”_blank” title=”{title}”><img src=”{pic}” alt=”{title}” width=”{picwidth}” height=”{picheight}”></a>
</div>
</li>
[/index]
[index=2]
<li style=”background:#f03540; display:none;”>
<div class=”w1240″>
<a href=”{url}” target=”_blank” title=”{title}”><img src=”{pic}” alt=”{title}” width=”{picwidth}” height=”{picheight}”></a>
</div>
</li>
[/index]
[index=3]
<li style=”background:#0f51b2;display:none;”>
<div class=”w1240s”>
<a href=”{url}” target=”_blank” title=”{title}”><img src=”{pic}” alt=”{title}” width=”{picwidth}” height=”{picheight}”></a>
</div>
</li>
[/index]
[index=4]
<li style=”background:#14a094;display:none;”>
<div class=”w1240s”>
<a href=”{url}” target=”_blank” title=”{title}”><img src=”{pic}” alt=”{title}” width=”{picwidth}” height=”{picheight}”></a>
</div>
</li>
[/index]
[index=5]
<li style=”background:url(https://www.banban.so/new/8.jpg) no-repeat center;display:none;”>
<div class=”w1240s”>
<a href=”{url}” target=”_blank” title=”{title}”><img src=”{pic}” alt=”{title}” width=”{picwidth}” height=”{picheight}”></a>
</div>
</li>
[/index]
</ul>
<div class=”w1240s focus-btn”>
<a href=”javascript:void(0)” class=”left-btn”></a>
<a href=”javascript:void(0)” class=”right-btn”></a>
</div>
</div>
</div>

5、将以下的CSS文件放到extend_common.css特别下方

.i-focus{height:470px;position:relative;margin-top:-4px}
.i-focus .if-inner{height:470px;overflow:hidden;position:relative}
.i-focus .if-inner .left-btn,.i-focus .if-inner .right-btn{position:absolute;display:block;width:58px;height:81px;top:194px;z-index:3;overflow:hidden;display:none}
.i-focus .if-inner .left-btn{left:10px;background:url(arrow.png) no-repeat}
.i-focus .if-inner .left-btn:hover{background-position:-118px 0}
.i-focus .if-inner .right-btn{right:10px;background:url(https://www.banban.so/new/css/images/arrow.png) no-repeat -59px 0}
.i-focus .if-inner .right-btn:hover{background-position:-177px 0}
.i-focus .focus-btn{position:relative}
.i-focus li{height:470px;width:100%;overflow:hidden;zoom:1;position:absolute}
.i-focus .focus-dot{position:absolute;top:445px;overflow:hidden;zoom:1;z-index:5}
.i-focus .focus-dot a{display:block;width:9px;height:9px; border:1px solid #fff; border-radius:5px; float:left;display:inline;margin:0 5px;overflow:hidden}
.i-focus .focus-dot .on{background:#fff}
.w1240{width:1240px; text-align:center; margin:0 auto}
.w1240s {width: 1240px; margin: 0 auto;}
.btnss{display:block;width:112px;height:40px;background-color:#148cbe;line-height:40px;text-align:center;font-size:15px;color:white;font-weight:normal; border:none; float:left; cursor:pointer; border-radius:5px;}
.btnss:hover{background-color:#2ca1d1;}
.btnsss{display:block;width:112px;height:40px;background-color:#ef6b00;line-height:40px;text-align:center;font-size:15px;color:#fff!important;font-weight:normal; border:none; float:left; cursor:pointer; border-radius:5px;}
.btnsss:hover{background-color:#ee7513;}

本站整理分享,如若转载请注明出处,本文地址:https://www.jaluoseo.com/wzjs/discuz/720.html

发表评论

登录后才能评论
网站建设
网站建设
青岛seo
青岛seo
网站优化
网站优化
分享本页
返回顶部
承接青岛网站建设,青岛seo,青岛网站优化以及北京、上海、深圳等各个地区和城市的企业、个人网站搭建和网站seo优化服务,咨询VX:jaluo2021