⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 search.asp

📁 ASP秀智能搜索 ASP秀智能搜索 ASP秀智能搜索 ASP秀智能搜索
💻 ASP
字号:
<%

Function bytes2BSTR(vIn) 
strReturn = "" 
For i = 1 To LenB(vIn) 
ThisCharCode = AscB(MidB(vIn,i,1)) 
If ThisCharCode < &H80 Then 
strReturn = strReturn & Chr(ThisCharCode) 
Else 
NextCharCode = AscB(MidB(vIn,i+1,1)) 
strReturn = strReturn & Chr (CLng(ThisCharCode) * &H100 + CInt(NextCharCode)) 
i = i + 1 
End If 
Next 
bytes2BSTR = strReturn 
End Function 

dim Sword,page,Url,SourceCode,Setop,Scondent,SeEnd,SePage
dim tt1,tt2
dim betw,first

Sword=trim(Request("word"))
if Sword="" then
response.redirect "./"
response.end
end if

if Request("pn")="" then
page=1
else
page=Request("pn")
end if

Url = "http://www1.baidu.com/baidu?word="&Sword&"&pn="&page&"&cl=3&ct=0&lm=0&si=&rn=&tn=aspshow&ie=gb2312&bs="&Sword
set oSend=createobject("Microsoft.XMLHTTP")
SourceCode = oSend.open ("GET",url,false) 
oSend.send()

if err.number<>0 then
Response.write err.description
Response.End()
end if  

SourceCode = bytes2BSTR(oSend.responseBody)
'response.write SourceCode
'response.end
if instr(SourceCode,"相关网页0篇")>0 then
Scondent="<br><table width=750 border=0 id=table1><tr><td vAlign=top colSpan=2 style=font-size: 9pt; line-height: 18px><font style=FONT-SIZE: 12pt>未找到相关结果,建议您:</font></td><td vAlign=top rowSpan=2 style=font-size: 9pt; line-height: 18px> </td></tr><tr><td width=100 style=font-size: 9pt; line-height: 18px> </td><td vAlign=top width=70% style=font-size: 9pt; line-height: 18px><font style=FONT-SIZE: 12pt><ol><li>检查输入文字有无错误,或换用更少的文字查询。<br><br></li><li>到<a href=http://www.aspshow.net/forum/>搜索援助中心</a>寻求帮助,或学习<a href=jiqiao.html>搜索技巧</a>。 </li></ol></font></td></tr></table></br>"
else
betw=instr(SourceCode,"<TABLE bgColor=#e6e6e6 border=0 cellPadding=0 cellSpacing=0 width=")-instr(SourceCode,"<tr><td align=right><font class=c size=""-1"">到<a href=""http://forum.baidu.com/cgi-bin/forum/board_show.cgi?id=1&age=60"">搜索援助中心</a>") 
first=instr(SourceCode,"<TABLE bgColor=#e6e6e6 border=0 cellPadding=0 cellSpacing=0 width=") 
SourceCode = Mid(SourceCode,first,abs(betw))
SourceCode =replace(SourceCode,"/baidu?","search.asp?")
tt1=split(SourceCode,"<ol>")
Setop="ASP秀搜索"&Mid(tt1(0),instr(tt1(0),"为"),abs(instr(tt1(0),"为")-instr(tt1(0),"秒")))&"秒"

tt2=split(left(tt1(1),instr(tt1(1),"</ol>")+4),"<p class=p2>")
num1=ubound(tt2)
if num1=0 then
tt2=split(tt1(1),"<p class=""p2"">")
num2=ubound(tt2)
end if
if num2>0 then
num1=num2
end if
if num1<>0 then
Scondent="<br><ol>"
for i =1 to int(num1)
 if instr(tt2(i),"class=c>百度快照</a>")>0 then
  Scondent = Scondent&"<p class=p2>"&left(tt2(i),instr(tt2(i),"> - <a"))&replace(right(tt2(i),len(tt2(i))-instr(tt2(i),"百度快照</a>")-7),"baidu?","search.asp?")
 else
  if instr(tt2(i),"</table>")=0 then
  Scondent = Scondent&"<p class=p2>"&tt2(i)
  end if
 end if
next
end if

SePage="<img border=0 src=images/bz.gif width=43 height=52 align=absmiddle> &nbsp;"&replace(replace(left(tt1(2),instr(tt1(2),"</ol>")-1),"baidu?","search.asp?"),"baidu","aspshow")
dim SD
 SD=instr(SePage,"<p>")
 if SD>0 then
  SePage=left(SePage,SD-1)
 end if
SePage="<table border='0' style='border-collapse: collapse' width='100%' cellpadding='0'><tr><td width='11'><img border='0' src='images/pageleft.gif' width='11' height='56'></td><td background='images/pagebg.jpg'><b>"&SePage&"</b></td><td background='images/pagebg2.gif' width='52'><a href='#'><img border='0' src='images/gotop.gif' width='52' height='27'></a></td><td width='13'><img border='0' src='images/pageright.gif' width='13' height='56'></td></tr></table>"
if instr(tt1(2),"<table")>0 and instr(tt1(2),"</table>")>0 then
 SeEnd=replace(replace(replace(mid(tt1(2),instr(tt1(2),"<table"),instr(tt1(2),"</table>")+8-instr(tt1(2),"<table")),"baidu?","search.asp?"),"baidu","aspshow"),">>更多相关搜索...","")&"</td></tr></table>"
end if
end if
%>
<html>
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<META content="ASP秀,asp秀搜索,http://www.aspshow.net,aspshow,aspshow.net" name=keywords>
<META content="ASP秀,asp秀搜索,http://www.aspshow.net,aspshow,aspshow.net" name=description>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>ASP秀,asp秀搜索</title>
<link href="images/style.css" rel="stylesheet" type="text/css">
</head>
<body topmargin="0" leftmargin="0">
<!--#include file="head.inc"-->
  <table align="center" style="BORDER-COLLAPSE: collapse" borderColor="#111111" height="22" cellPadding="0" width="750" border="0" bgcolor="#F0F0F0">
    <tbody>
      <form action="search.asp" method=get name=aspshow><tr>
        <td height="35"><img src= http://un.baidu.com/images/st.gif?tn=aspshow width=0 height=0>
		<input class="ibox" size="70" name="word" value="<%=Sword%>"><input type="image" alt="搜" src="images/search_but.gif" align="absMiddle" border="0"> </td>
      </tr></form>
    	<tr>
        <td height="9">
		<table cellSpacing="0" cellPadding="0" width="100%" border="0" id="table2">
			<tr bgColor="#5d90de">
				<td width="20" background="result_back1.gif" bgcolor="#16A6D3">
				<br>
 </td>
				<td vAlign="bottom" background="result_back1.gif" height="30" bgcolor="#16A6D3"><!-- search bar -->
				<table cellSpacing="0" cellPadding="0" border="0" id="table3">
					<tr align="middle">
						<td width="7">
						<img height="26" src="images/result_left1.gif" width="7" border="0"></td>
						<td noWrap width="70" background="images/result_back2.gif">
						<b class="title1">网页搜索</b></td>
						<td width="7">
						<img height="26" src="images/result_right1.gif" width="7" border="0"></td>
						<td noWrap width="90"><b><a href="msearch.asp?word=<%=server.urlencode(Sword)%>" class=title2>音乐搜索</a></b></td>
						<td noWrap width="90"><b><a href="flash.asp?word=<%=server.urlencode(Sword)%>" class=title2>动画搜索</a></b></td>
						<td noWrap width="90"><b><a href="news.asp?word=<%=server.urlencode(Sword)%>" class=title2>新闻搜索</a></b></td>
						<td noWrap width="90"><b><a href="pic.asp?word=<%=server.urlencode(Sword)%>" class=title2>图片搜索</a></b></td>
					</tr>
				</table>
				</td>
				<td vAlign="top" noWrap align="right" background="result_back1.gif" height="30" bgcolor="#16A6D3">
				<img height="21" src="images/result_dot1.gif" width="14" border="0">
				<a class="title3" target="_blank" href="http://www.aspshow.net/forum/">登录论坛</a> <img height="21" src="images/result_dot1.gif" width="14" border="0"><a class="title3" href="#" onClick="MM_popupMsg('    ===广=告=服=务===\r\r广告联系方式:QQ8963017 TEL:13972379802(周)\r\r    ===合=作=愉=快===')">广告服务</a></td>
			</tr>
		</table>
			</td>
      </tr>
    </tbody>
  </table>
  <table align="center" style="BORDER-COLLAPSE: collapse" borderColor="#111111" height="181" cellSpacing="8" cellPadding="2" width="750" border="0">
    <tbody>
      <tr>
        <td vAlign="top" height="250" width=70%>
		<p> <%=Setop%> 
		<table cellspacing=10 cellpadding=0 border=0 width=100%>
	<tr><td background=images/result_line.gif><spacer type=block height=1></table>
	<%=Scondent%><%=SeEnd%><table cellspacing=10 cellpadding=0 border=0 width=100%>
	<tr><td background=images/result_line.gif><spacer type=block height=1></table>
	<%=SePage%>
	</td>
        <td vAlign="top" width="30%" height="250" align="right">
		<table border="0" style="border-collapse: collapse" width="200" cellpadding="0" id="table4" bgcolor="#F0F0F0" height="167">
			<tr>
				<td height="25">
				<table cellSpacing="0" cellPadding="0" width="100%" border="0" id="table5">
					<tr>
						<td width="26">
						<img height="25" src="images/index_left5.gif" width="30" border="0"></td>
						<td class="p6" vAlign="bottom" width="100%" background="images/index_back5.gif">
						<font color="#5c5c5c"><b>推荐网站</b></font></td>
						<td width="12">
						<img height="25" src="images/index_right5.gif" width="13" border="0"></td>
					</tr>
				</table>
				</td>
			</tr>
			<tr>
				<td><!--#include file="webtj.inc"--></td>
			</tr>
			<tr>
				<td><!--#include file="ad.inc"--> </td>
			</tr>
		</table>
		</td>
      </tr>
    </tbody>
  </table>
<!--#include file="bottom.inc"--></body>

</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -