点击按影片名搜索还行.但是点下一页就提示"
点击按演员搜索就提示search.asp错误
line 312是:set rs=conn.execute(sql)
我是用frontpage打开的:
'---------------------------search----------------------
name=trim(request("keyword"))
name=replace(name,"'","''")
'Response.Write name
if request("typeid")="片名" then
sql="select * from learning where title Like '%"& name &"%' and unlook=0 or title like title Like '%"& name &"%' and unlook=0 or title Like '%"& name &"%' and unlook=0 order by articleid desc"
else
sql="select * from learning where name Like '%"& name &"%' and unlook=0 or name like name Like '%"& name &"%' and unlook=0 or name Like '%"& name &"%' and unlook=0 order by articleid desc"
end if
set rs=conn.execute(sql)
'Rsponse.Write rs.RecordCount
if name="" then
'response.redirect"index.asp"
response.write"<script>alert('查找字符不能为空格,请重输入查找的内容!请您返回重查');</Script><script Language=Javascript>location.href = '';</script>"
response.end
elseif rs.eof then
response.write"<script>alert('对不起,暂时还没有你要查找的演员或影片! 请您返回重查');</Script><script Language=Javascript>location.href = '';</script>"
response.end
else
Set rs= Server.CreateObject("ADODB.Recordset")
rs.open sql,conn,1,1
'set rs=server.createobject("ADODB.recordset")
'rs.open sql,conn
'searchsub rs
end if
%>
<%
const MaxPerPage=10
dim totalPut
dim CurrentPage
dim TotalPages
dim i,j
dim typename
typename="软件搜索结果"
if not isempty(request("page")) then
currentPage=cint(request("page"))
else
currentPage=1
end if
set rst=server.CreateObject("ADODB.RecordSet")
%>
哪为高高手帮我改改啊!小弟感激不尽!