SOURCE

console 命令行工具 X clear

                    
>
console
need("biz.scroll",function(s){
	//左右滚动js代码
	s.init({
	conId:'rollbox_ad',//内容容器ID
	//leftId:'m_right',//左箭头ID
	//rightId:'m_left',//右箭头ID
	frameWidth:'590',//显示框宽度
	pageSpace:'590',//翻页宽度或高度
	autoPlay:true,//true为自动播放、false为不自动播放
	position:'left',//播放方向 left为向左,up为向上,设置为up时必须加上翻页高度pageHeight值
	autoPlayTime:'2',//自动播放间隔时间(秒)
	dotListId:'do'//是否需要分页,不需要则删掉此行,并将页面上相应代码去掉,如此例分页代码为<div id="do" class="do"></div>,删掉即可
	});
})
<div class="content-ads">
    <div class="demo-item">
        <div id="rollbox_ad">
            <ul class="p-show">
                <li><img src="http://ossweb-img.qq.com/images/igame/lolmatch/banner.jpg" width="590" height="240" alt=" " /></li>
                <li><img src="http://ossweb-img.qq.com/images/igame/lolmatch/banner.jpg" width="590" height="240" alt=" " /></li>
                <li><img src="http://ossweb-img.qq.com/images/igame/lolmatch/banner.jpg" width="590" height="240" alt=" " /></li>
            </ul>
        </div>
        <div id="do" class="do"></div>
    </div>
</div>
* { margin:0; padding:0}
.content-ads
{ width:590px;height:240px; float:left}
.demo-item
{float:left; width:590px; height:240px; display:block; overflow:hidden; position:relative;}
.demo-item li
{float:left; width:590px; height:240px; display:block; overflow:hidden}
.do{position:absolute; bottom:12px; right:12px; overflow:hidden; zoom:1;}
.do:after
{content:"."; display:block; height:0; clear:both; visibility:hidden;}
.do span
{background:#aaaaaa; float:left; width:20px; height:7px; display:block; overflow:hidden; text-indent:-9999px; cursor:pointer; cursor:hand; border:1px solid #d0d0d0; margin-right:8px;}
.do span.dotItem
{background:#f96400; border:1px solid #d0d0d0;}

本项目引用的自定义外部资源