Thinkcmf3.2完美解决幻灯片循环

发布日期:2017-11-29 12:17:13

内容摘要:关于幻灯片的循环
关于幻灯片的循环
    <!--
              作者:lmkay@sina.cn
              时间:2017-11-29
              描述:幻灯片开始
          -->
            <div class="section " id="section0">
                <div class="wrap">
                    <div style="    width: 100%;padding-left: 60px;padding-right: 300px;">
                        <div id="myCarousel" class="carousel slide">
                            <!-- 轮播(Carousel)指标 -->
                            <ol class="carousel-indicators">
                                <li data-target="#myCarousel" data-slide-to="0" class="active"></li>
                                <li data-target="#myCarousel" data-slide-to="1"></li>
                                <li data-target="#myCarousel" data-slide-to="2"></li>
                            </ol>
                            <!-- 轮播(Carousel)项目 -->
                            <div class="carousel-inner">
                                <php>
                                    $home_slides=sp_getslide("portal_index"); $home_slides=empty($home_slides)?$default_home_slides:$home_slides;
                                </php>

                                <foreach name="home_slides" item="vo">

                                    <div class="item  {$key==0?'active':''}">
                                        <img src="{:sp_get_asset_upload_path($vo['slide_pic'])}" alt="First slide">
                                    </div>

                                </foreach>

                            </div>
                            <!-- 轮播(Carousel)导航 -->
                            <a class="carousel-control spite_span left" href="#myCarousel" data-slide="prev"></a>
                            <a class="carousel-control spite_span right " href="#myCarousel" data-slide="next"></a>
                        </div>
                    </div>
                </div>
            </div>

            <!--
            作者:lmkay@sina.cn
            时间:2017-11-29
            描述:幻灯片结束
        -->





推荐商品

赞助商广告