首页上一页");
else if(countPage>1&¤tPage!=0&¤tPage==1)
document.write("
首页上一页");
else
document.write("
首页");
//循环
//var num = 5;
//for(var i=0+(currentPage-1-(currentPage-1)%num) ; i<=(num+(currentPage-1-(currentPage-1)%num))&&(i
countPage)endpage=countPage;
startPage=endpage-5;
if(startPage<0) startPage=0;
for(var i=startPage; i"+(i+1)+"");
else if(i==0){
document.write(""+1+"");
}else
document.write(""+(i+1)+"");
}
//设置下一页代码
if(countPage>1&¤tPage!=(countPage-1))
document.write("下一页尾页");
else
document.write("尾页");
//跳转页面
document.write("跳/" + countPage + "页"+"");
function toPage(){
var _num = document.getElementById("num").value;
var str = "index"+"_"+(_num-1)+"."+"html";
var url = location.href.substring(0,location.href.lastIndexOf("/")+1);
if(_num<=1||_num==null)
location.href = url+"index"+"."+"html";
else if(_num>countPage)
alert("本频道最多"+countPage+"页");
else
location.href = url+str;
}