搜索分页出错,好心人帮帮忙

来源:百度知道 编辑:UC知道 时间:2024/06/04 01:54:00
分页代码
<%
if page<>1 then
%>
<a href='jieguo.asp?sous=<%=request("sous")%>?page=<%=page-1%>'>上一页</a>
<%end if%>
<%if rs.eof then%>
<%else%>
<a href='jieguo.asp?sous=<%="&request('sous')&"%>?page=<%=page+1%>'>下一页</a>
<%end if%>

点击下一页的时候网页就打不开了

又是你啊,我都给你代码了你照着一改不好吗,哎,光贴个这看不出来

给你改了半天 你运行还有什么错误,你里面少了很多end if,asp 有一个if 就要有一个end if
<%
bt=request("sous")
if request("hcgood")<>"" then session("hcgood")=request("hcgood")
sql = "select * from shuju where bt like '"&bt&"' and cs='0771' order by gx2 desc"
Set rs = Server.CreateObject("ADODB.RecordSet")
rs.Open sql,conn,1,1
if rs.recordcount=0 then
response.write "<br> 共找到<font color=#ff0000> 0 </font>条您所需要的信息!"
response.end
end if
end if
page=cint(request.QueryString ("page"))
rs.PageSize=40
pagecount=rs.pagesize
if page<=0 then page=1
end if
if request.QueryString("page")="" then page=1
end if
rs.AbsolutePage=page
gg=rs.recordcount/pagecount
gh=cint(gg)
if gh<=1 then gh=1
end if
if gg&g