📄 search.asp
字号:
<td colspan="2">
<%
dim rstype
dim typesql
dim okname,typename1
'---------------------------search----------------------
name=trim(request("keyword"))
name=replace(name,"'","''")
'Response.Write name
if request("typeid")="片名" then
sql="select * from learning where title Like '%"& name &"%' or title like title Like '%"& name &"%' or title Like '%"& name &"%'order by articleid desc"
else
sql="select * from learning where name Like '%"& name &"%' or name like name Like '%"& name &"%' or name Like '%"& name &"%'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")
%> <%
' dim sql
'dim rs
'if request("hits")="1" then
' sql="select * from learning order by hits desc"
'else
' sql="select * from learning order by articleid desc"
'end if
'Set rs= Server.CreateObject("ADODB.Recordset")
'rs.open sql,conn,1,1
if rs.eof and rs.bof then
response.write "<script>alert('暂时还没有您要找的影片,请与管理员联系!')</Script>"
response.end
else
totalPut=rs.recordcount
totalPut=rs.recordcount
if currentpage<1 then
currentpage=1
end if
if (currentpage-1)*MaxPerPage>totalput then
if (totalPut mod MaxPerPage)=0 then
currentpage= totalPut \ MaxPerPage
else
currentpage= totalPut \ MaxPerPage + 1
end if
end if
if currentPage=1 then
showpage totalput,MaxPerPage,"search.asp"
showContent
showpage totalput,MaxPerPage,"search.asp"
else
if (currentPage-1)*MaxPerPage<totalPut then
rs.move (currentPage-1)*MaxPerPage
dim bookmark
bookmark=rs.bookmark
showpage totalput,MaxPerPage,"search.asp"
showContent
showpage totalput,MaxPerPage,"search.asp"
else
currentPage=1
showpage totalput,MaxPerPage,"search.asp"
showContent
showpage totalput,MaxPerPage,"search.asp"
end if
end if
end if
sub showContent
'<!--
'Generator: http://w w w . 4 1 76 0 0 . n e t
'Creation Data: 2004-11-29
'Original Author: Qq7 51 4 6 Qq1 1 81 9 0
'-->
'Split("Sun,Mon,Tue,Wed,Thu,Fri,Sat",",")
BgImg1 = "06,04,08,09"
BgImg2 = "12,11,14,15"
dim i
i=0
%>
<%i=0
do while not rs.eof
If i mod 2 = 0 Then MyBgImg = BgImg1 Else MyBgImg = BgImg2
MyBgImg = Split(MyBgImg,",")
%>
</td>
</tr>
<tr><td valign="top">
<table width="255" border="0" align="right" bordercolorlight="#000000" class="y" cellpadding="0">
<tr>
<td width="121" rowspan="2" valign="top">
<TABLE width="115" height="144" border=0 cellPadding=0 cellSpacing=0 background="images/image_bg.gif">
<TR>
<TD height=16 align=middle vAlign=center>
<img src="images/spacer.gif" width="1" height="1"></TD>
</TR>
<TR>
<TD align="center"><a target="_blank" title="影片名称:<%=rs("title")%>
主演:<%content=rs("name")
if len(content)>8 then content=left(content,8)&"…"
response.write content
%>
上传时间:<%=rs("dateandtime")%>
观看次数:<%=rs("hits")%>次
罗村在线--宽频影院系统欢迎您
联系QQ:372481373" href="movie.asp?id=<%=rs("articleid")%>"><img border="0" height="119" src="<%if rs("domurl")="" then%>img/w.gif<%else%><%=rs("domurl")%><%end if%>" width="100"></a></TD>
</TR>
<TR>
<TD height=9><IMG height=1
src="images/spacer.gif"
width=1></TD>
</TR>
</TABLE></td>
<td>
<span class="3dfont2"><a target="_blank" title="影片名称:<%=rs("title")%>
主演:<%content=rs("name")
if len(content)>8 then content=left(content,8)&"…"
response.write content
%>
上传时间:<%=rs("dateandtime")%>
观看次数:<%=rs("hits")%>次
罗村在线--宽频影院系统欢迎您
联系QQ:372481373" href="movie.asp?id=<%=rs("articleid")%>"><strong><%content=rs("title")
if len(content)>13 then content=left(content,13)&""
response.write content
%></strong></a>
</span>
</td>
</tr>
<tr>
<td>
<IMG height=15 src="images/fang.gif" width=15>类型:
<%=rs("typeid")%><br>
<IMG height=15 src="images/fang.gif"
width=15>主演:<%content=rs("name")
if len(content)>5 then content=left(content,5)&"…"
response.write content
%><BR>
<IMG height=15
src="images/fang.gif" width=15>上传: <span class="eng_S"><%=rs("dateandtime")%></span><BR>
<IMG
height=15 src="images/fang.gif" width=15>观看: <%=rs("hits")%>次<br>
<IMG
height=15 src="images/fang.gif" width=15>级别: <strong><img border="0" src="img/<%=rs("softlevel")%>STAR.GIF"></strong><br>
<IMG
height=15 src="images/fang.gif" width=15>开放: <% if rs("canlook")=1 then%>
普通电影
<%elseif rs("canlook")=3 then%>
黄金电影
<%elseif rs("canlook")=0 then%>
免费电影
<%end if%>
</TD>
</TR>
<TR height=2>
<TD background="images/---.jpg" colSpan=2></TD>
</TR>
</TABLE><%rs.movenext%></td>
<td><% If not rs.eof Then %><table width="255" align="left" border="0" bordercolorlight="#000000" class="y" cellpadding="0">
<tr>
<td width="121" rowspan="2" valign="top">
<TABLE width="115" height="144" border=0 cellPadding=0 cellSpacing=0 background="images/image_bg.gif">
<TR>
<TD height=16 align=middle vAlign=center>
<img src="images/spacer.gif" width="1" height="1"></TD>
</TR>
<TR>
<TD align="center"><a target="_blank" title="影片名称:<%=rs("title")%>
主演:<%content=rs("name")
if len(content)>8 then content=left(content,8)&"…"
response.write content
%>
上传时间:<%=rs("dateandtime")%>
观看次数:<%=rs("hits")%>次
罗村在线--宽频影院系统欢迎您
联系QQ:372481373" href="movie.asp?id=<%=rs("articleid")%>"><img border="0" height="119" src="<%if rs("domurl")="" then%>img/w.gif<%else%><%=rs("domurl")%><%end if%>" width="100"></a></TD>
</TR>
<TR>
<TD height="9">
<img src="images/spacer.gif" width="1" height="1"></TD>
</TR>
</TABLE></td>
<td>
<span class="3dfont2"><strong></strong><a target="_blank" title="影片名称:<%=rs("title")%>
主演:<%content=rs("name")
if len(content)>8 then content=left(content,8)&"…"
response.write content
%>
上传时间:<%=rs("dateandtime")%>
观看次数:<%=rs("hits")%>次
罗村在线--宽频影院系统欢迎您
联系QQ:372481373" href="movie.asp?id=<%=rs("articleid")%>"><strong><%content=rs("title")
if len(content)>13 then content=left(content,13)&""
response.write content
%></strong></a></span></TD>
</tr>
<tr>
<td>
<IMG height=15 src="images/fang.gif" width=15>类型:
<%=rs("typeid")%><br>
<IMG height=15 src="images/fang.gif"
width=15>主演:<%content=rs("name")
if len(content)>5 then content=left(content,5)&"…"
response.write content
%><BR>
<IMG height=15
src="images/fang.gif" width=15>上传: <span class="eng_S"><%=rs("dateandtime")%></span><BR>
<IMG
height=15 src="images/fang.gif" width=15>观看: <%=rs("hits")%>次<br>
<IMG
height=15 src="images/fang.gif" width=15>级别: <strong><img border="0" src="img/<%=rs("softlevel")%>STAR.GIF"></strong><br>
<IMG
height=15 src="images/fang.gif" width=15>开放: <% if rs("canlook")=1 then%>
普通电影
<%elseif rs("canlook")=3 then%>
黄金电影
<%elseif rs("canlook")=0 then%>
免费电影
<%end if%>
</TD>
</TR>
<TR height=2>
<TD background="images/---.jpg" colSpan=2></TD>
</TR>
</table><%rs.movenext%>
</td>
</tr>
<tr>
<% End If %>
</tr>
<tr>
<td colspan="2">
<% i=i+2
if i>=MaxPerPage then exit do
loop
%>
</td>
</tr>
</table> <%
end sub
function showpage(totalnumber,maxperpage,filename)
dim n
if totalnumber mod maxperpage=0 then
n= totalnumber \ maxperpage
else
n= totalnumber \ maxperpage+1
end if
%>
<table border="0" cellspacing="0" height="25" width="511" background="images/top-bg3.gif">
<form method=Post action="<%=filename%>?typeid=<%=typeid%>">
<tr><td>
<font color="000000" class="fontshadow">〓 <%=typeid%> 〓 共有<font color="ff0000"><b><%=totalnumber%></b></font>部 当前:第<font color="ff0000"><strong><%=CurrentPage%></strong></font>页/共<font color="ff0000"><strong><%=n%></strong></font>页</center>
<td><div align="right">
<%if CurrentPage<2 then%>
<font color="888888">首页 上一页
<%else%>
<a class=left href="<%=filename%>?typeid=<%=typeid%>&page=1&"><font color="000000">首页</a>
<a class=left href="<%=filename%>?typeid=<%=typeid%>&page=<%=CurrentPage-1%>"><font color="000000">上一页</a>
<%
end if
if n-currentpage<1 then
%>
<font color="888888">下一页 尾页
<%else%>
<a class=left href="<%=filename%>?typeid=<%=typeid%>&page=<%=(CurrentPage+1)%>"><font color="000000">下一页</a>
<a class=left href="<%=filename%>?typeid=<%=typeid%>&page=<%=n%>"><font color="000000">尾页</a>
<%end if%>
</div>
<td align="center"><select name="page" style="color:#000000;font-size: 9pt" onchange="javascript:submit()">
<%for i = 1 to n%>
<option value="<%=i%>" <%if cint(CurrentPage)=cint(i) then%> selected <%end if%>>第<%=i%>页</option>
<%next%></select></td>
</tr></form></table>
<%
end function
%>
<%
sub gotopage
end sub
%>
</TABLE>
<!--#include file=Bottom.asp-->
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -