一个上下 移动后的翻页问题
在每页的最后一行下移的时候不能到下一页, 这是为什么。 而是直接到了最后一页 同样第二页的第一条上移应该返回第一页啊 他也直接到了第三页
郁闷中 请求帮助
我的翻页是这样的
<%
if request( "new_select ") <> " " then
sql= "lanchina_new_manage_query "&request( "new_select ")& ", ' "&request( "new_key ")& " ' "
else
sql= "lanchina_new_manage "
end if
set rscyc=server.CreateObject( "adodb.recordset ")
rscyc.CursorLocation = 3
rscyc.open sql,conn,1,3
i=0
if rscyc.eof then
response.write( "目前还没有新闻纪录!! ")
else
rscyc.pagesize=5
if request( "page ")= " " then
session( "page ")=1
else
session( "page ")=eval(session( "page ") & request( "page "))
if session( "page ") <1 then
session( "page ")=1
end if
if session( "page ")> rscyc.PageCount then
session( "page ")=rscyc.PageCount
end if
end if
rscyc.AbsolutePage=session( "page ")
j=0
do while not rscyc.eof and j <rscyc.pagesize
j=j+1
i=rscyc.pagesize*(session( "page ")-1)+j
%>
<tr>
<td> <span class= "STYLE9 ">
<label>
<input type= "checkbox " name= "new_id " value= " <%=rscyc( "new_id ")%> "/>
</label>
</span> </td>
<td> <span class= "STYLE9 "> <%=Server.HtmlEncode(left(rscyc( "new_title "),12))%> </span> </td>
<td> <span class= "STYLE9 "> <%=Server.HtmlEncode(rscyc( "new_titlesub "))%> </span> </td>
<td> <span class= "STYLE9 "> <%=Server.HtmlEncode(rscyc( "new_person "))%> </span> </td>
<td> <span class= "STYLE9 "> <%=Server.HtmlEncode(rscyc( "new_readcount "))%> </span> </td>
<td> <span class= "STYLE9 "> <%=rscyc( "new_passed ")%> </span> </td>
<td> <span class= "STYLE9 "> <%=rscyc( "new_top ")%> </span> </td>
<td> <span class= "STYLE9 "> <%=rscyc( "new_type ")%> </span> </td>
<td>
<%
If i=1 then
response.write "no "
%>
<%else
if j=1 then
page=session( "page ")-1
else
page=session( "page ")
end if
%>
<a href= "up_pro.asp?new_idsub= <%=rscyc( "new_idsub ")%> &page= <%=page%> &j= <%=j%> ">
<font color= "blue "> 上移 </font> </a>
<%End if%> |
<%If i=rscyc.recordcount then
response.write "no "
%>
<%else
if j=rscyc.pagesize then
page=session( "page ")+1
else
page=session( "page ")
end if
%>
<a href= "down_pro.asp?new_idsub= <%=rscyc( "new_idsub ")%> &page= <%=page%> ">
<font color= "blue "> 下移 </font> </a>
<%End if%>
</td>
</tr>
<%
rscyc.movenext
loop
' end if
%>
[解决办法]
最怕一上来描述都描述不清楚就刷刷刷的贴代码的。
[解决办法]
和楼上有同感!现在都不清楚你提的是什么问题!
[解决办法]
<a href= "down_pro.asp?new_idsub= <%=rscyc( "new_idsub ")%> &page= <%=page%> ">
page应该+1吧?