Intra-site search script (2)

Source: Internet
Author: User
Tip: you can modify some code before running

<html><head><title>Intra-site search script (2)</title><style type="text/css"><!--body { font-family: "宋体"; font-size: 9pt; margin-top: 0px; margin-left: 0px; margin-right: 0px}A { COLOR: black; FONT-SIZE: 9pt; FONT-WEIGHT: 400; TEXT-DECORATION: none } A:hover { COLOR: red; FONT-SIZE: 9pt; FONT-WEIGHT: 400; TEXT-DECORATION: underline }a:active { font: 9pt "宋体"; cursor: hand; color: #FF0033 }--></style><meta http-equiv="Content-Type" content="text/html; charset=gb2312"></head><body><br><br><center><font color=red face="隶书" size=6>Intra-site search script (2)</font></center><br><br><center><table border=0 bordercolor=#111111 borderlight=green cellpadding="0" cellspacing="0"><tr><td align=center></td></tr><tr><td align=center width=300><SCRIPT LANGUAGE="JavaScript"> <!-- Hide Script from Old Browsers Keyword = new Object(); Descrip = new Object(); Address = new Object();// Keyword[0] = n (where n is the number of keywords which can be searchedKeyword[0] = 5 //对应查询组的数量;Keyword[1] = "javascript"Descrip[1] = "最全的javascript资源站-javascript2000.com"Address[1] = "http://www.javascript2000.com"Keyword[2] = "javascript"Descrip[2] = "很好的javascript站点"Address[2] = "http://www.cnlot.com/"Keyword[3] = "javascript"Descrip[3] = "java神捕"Address[3] = "http://pcafei.3322.net/"Keyword[4] = "javascript"Descrip[4] = "精彩天地"Address[4] = "http://demoy.3322.net/"Keyword[5] = "javascript"Descrip[5] = "国外最大的javascript资源站"Address[5] = "http://www.javascript.com/" function checkDatabase() { var Found = false var Item = document.forms[0].searchfor.value.toLowerCase();stats='toolbar=no,location=no,directories=no,status=no,menubar=no,' stats += 'scrollbars=yes,resizable=yes' MsgBox = window.open ("","msgWindow",stats) MsgBox.document.write("<head><title>查询结果</title></head>");MsgBox.document.write ("<BODY BGCOLOR=#ffffff TEXT=#000000 LINK=#000080 VLINK=#800040 ALINK=#FF0000><CENTER>查询结果</cENTER>") MsgBox.document.write ("关键字为: "+Item+"<HR>"); for (var i=1; i <= Keyword[0]; i++) { if(Item == Keyword[i]) { Found = true; MsgBox.document.write (Descrip[i]+"<BR>点击这里进入<br>") } } if(!Found)MsgBox.document.write ("没有发现与该关键词有关的条目。") // Leave the line below intact if you want to legally use this scriptMsgBox.document.write ("<H4>欢迎您!<BR>你的邮箱 </h4>")MsgBox.document.write ("<FORM class='pt9'><CENTER>") MsgBox.document.write ("<INPUT type='button' value='关闭查询窗口' onClick = 'self.close()'>") MsgBox.document.write ("</cENTER></fORM>") } // --> </sCRIPT></p> <table width="100%" border="0" align="right" bordercolor="#111111" cellpadding="0" cellspacing="0"> <tr> <td height="126"> <form name="form1"> <u>Enter query keywords:</u><br> <input type="text" name="searchfor" value="" size=20> <input type="button" value="查询" onClick="checkDatabase()" name="button"> <p> <p>Enter the query keyword"<b><font face="Arial, Helvetica, sans-serif" size="3" color="#FF0000">Javascript</font></b>"Look at the query results.</form> </td> </tr> </table></td></tr></table></center><br><br><br><br></body></html>
Tip: you can modify some code before running

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.