87,984
社区成员
发帖
与我相关
我的任务
分享
$(document).ready(function(){
$("#slider1").Xslider({
// 默认配置
affect: 'scrollx', //效果 有scrollx|scrolly|fade|none
speed: 800, //动画速度
space: 4000, //时间间隔
auto: true, //自动滚动
trigger: 'click', //触发事件 注意用mouseover代替hover
conbox: '.conbox', //内容容器id或class
ctag: 'div.tsxwone', //内容标签 默认为<a>
switcher: '.switcher', //切换触发器id或class
stag: 'a', //切换器标签 默认为a
current:'cur', //当前切换器样式名称
rand:false //是否随机指定默认幻灯图片
});
});
<div id="slider1" class="zn15_sybigimg">
<div class="conbox">
<c:forEach items="${activitylist }" var="en">
<div class="tsxwone">
<c:if test="${en.hrefstring==null||en.hrefstring=='' }"><c:if test="${en.id=='4028863b4d92ea49014d9330de270000' }"><input type="button" value="Try It For Free Now!" onclick="window.location.href='${ctx}/login.jsp'" /></c:if><a href="${ctx }/activityinforcon!input.action?id=${en.id}" target="_blank" class="updatehotspot">
<img src="${ctx}${en.photoPath}" dir="hotspot_${en.id}" usemap="#hotspot_${en.id}"/>
<c:if test="${en.hotspot!=null&&en.hotspot!='' }">
${en.hotspot}
</c:if>
</a>
</c:if>
<c:if test="${en.hrefstring!=null&&en.hrefstring!='' }">
<a href="${en.hrefstring}" ${fn:indexOf(en.hrefstring,'cltguides')==-1?'target="_blank"':'' } class="updatehotspot">
<img src="${ctx}${en.photoPath}" dir="hotspot_${en.id}" usemap="#hotspot_${en.id}"/>
<c:if test="${en.hotspot!=null&&en.hotspot!='' }">
${en.hotspot}
</c:if>
</a>
</c:if>
</div>
</c:forEach>
</div>
<div class="switcher">
<c:forEach items="${activitylist }" var="en" varStatus="i"><a href="javascript:void(0);" ${i.index==0?"class='cur'":"" }></a></c:forEach>
</div>
</div>
正好我也学习下~