我有这样的jQuery代码:
var pageWidth = 230;
var sliderStartPosition = 0;
var sliderPageWidth = pageWidth;
function goToPage(slideNum){
var offset = (slideNum-1) * sliderPageWidth;
$('#js_slides').animate({left:'-'+offset+'px'}, 500, function(){
$('#js_slides li').each(function(){ this.scrollTop = 0; });
});
return false;
}
function goToPageWithoutAnimation(slideNum){
var offset = (slideNum-1) * sliderPageWidth;
//code here
}
这是CSS:
div.sliderContainer {
width: 230px; /*width of one page to slide*/
overflow: hidden;
}
div.sliderContainer ul {
position: relative;
width: 690px;
list-style: none;
list-style-type: none;
margin: 0px;
padding: 0px;
}
div.sliderContainer ul li{
float: left;
width: 210px;
height: 380px;
overflow: auto;
padding: 10px;
}
我需要你的帮助,如何在没有动画的情况下进入页面。请帮我。