濮阳杆衣贸易有限公司

主頁(yè) > 知識(shí)庫(kù) > 如何實(shí)現(xiàn)全文檢索?

如何實(shí)現(xiàn)全文檢索?

熱門標(biāo)簽:常州智能外呼電銷機(jī)器人如何 武漢如何辦理400電話 語(yǔ)音電銷機(jī)器人視頻 重慶400電話哪里辦理 教育機(jī)構(gòu)地圖標(biāo)注 自適應(yīng)地圖標(biāo)注 400電話是怎么申請(qǐng) 遼寧營(yíng)銷智能外呼系統(tǒng)價(jià)格多少 推銷電話機(jī)器人怎么打電話的

%@ LANGUAGE="VBscript" %>
  html>
  head>
  meta NAME="GENERATOR" Content="Microsoft FrontPage 3.0">
  meta HTTP-EQUIV="Content-Type" content="text/html; charset=gb_2312-80">
  title>星河影動(dòng)之全文檢索/title>
  meta name="Microsoft Border" content="tl, default">

/head>
   body BGPROPERTIES="FIXED" BGCOLOR="#00FFFF">

%
  mousepointer=13
  Set Conn1 = Server.CreateObject("ADODB.Connection")
  conn1.open "DSN=intels"
  Set rcst1 = conn1.execute("select * from pages_catalogue")
  sch_str=request.form("text1")
  doubbytes=len(sch_str)\2
  sch_str=left(sch_str,doubbytes)

' 匹配字串的長(zhǎng)度.預(yù)處理Request取得的數(shù)據(jù)(用戶輸入的有用信息), 通過計(jì)算有效信息長(zhǎng)度來截取所需的字串.我們也可以在輸入字串后附加一標(biāo)志字符(如#chr(7))來處理.
  Response.Write "CENTER>檢索結(jié)果HR>Br>"
  Dim result
  result =false
  Response.Write "UL>"
  do while not rcst1.eof
  tit=rcst1.fields("file_title")
  fn=rcst1.fields("file_name")
  file_name= Server.MapPath ("/") "\song\chunfeng\" fn
  to_find=text_match(file_name,sch_str)

' 逐個(gè)打開記錄集中當(dāng)前記錄所指向的文件。用查找的字串對(duì)文件的全文本進(jìn)行匹配比較.
  if to_find then
  url="chunfeng/" fn
  Response.Write "A HREF=" url ">
" tit
  end if
  rcst1.movenext
  result=result or to_find
  loop
  Response.Write "/UL>"

' 符合條件的文件標(biāo)題以超級(jí)鏈接形式輸出到客戶端.
  if not result then
  Response.Write "對(duì)不起,沒有找到!"
  end if
  mousepointer=0
  %>
  script RUNAT="Server" LANGUAGE="VBScript">
  function text_match(filename,search_string)
  dim retstring
  dim find_pos
  Dim fso, a
  dim done
  text_match=false
  Set fso = Server .CreateObject("Scripting.FileSystemObject
")

' 創(chuàng)建腳本的文件系統(tǒng),打開文本流以讀入.
  Set a = fso.OpenTextFile(filename, 1, FALSE)

done=a.AtEndOfStream or text_match
  Do While not done
  retstring = a.ReadLine
  find_pos=instr(retstring,search_string)
  if find_pos>0 then text_match=true
  done=a.AtEndOfStream or text_match
  Loop
  a.Close
  end function
  /script>
  /body>/html>

[1]

您可能感興趣的文章:
  • SqlServer 2005 簡(jiǎn)單的全文檢索
  • SQL Server全文檢索查詢淺析
  • flex 實(shí)現(xiàn)全文檢索中的高亮顯示代碼
  • Oracle9i的全文檢索技術(shù)開發(fā)者網(wǎng)絡(luò)Oracle
  • 開發(fā)實(shí)例:JSP中實(shí)現(xiàn)全文檢索
  • 全文檢索技術(shù) sql server
  • SQLServer 全文檢索(full-text)語(yǔ)法

標(biāo)簽:襄陽(yáng) 中山 雞西 邯鄲 威海 朔州 遵義 柳州

巨人網(wǎng)絡(luò)通訊聲明:本文標(biāo)題《如何實(shí)現(xiàn)全文檢索?》,本文關(guān)鍵詞  如何,實(shí)現(xiàn),全文檢索,如何,;如發(fā)現(xiàn)本文內(nèi)容存在版權(quán)問題,煩請(qǐng)?zhí)峁┫嚓P(guān)信息告之我們,我們將及時(shí)溝通與處理。本站內(nèi)容系統(tǒng)采集于網(wǎng)絡(luò),涉及言論、版權(quán)與本站無(wú)關(guān)。
  • 相關(guān)文章
  • 下面列出與本文章《如何實(shí)現(xiàn)全文檢索?》相關(guān)的同類信息!
  • 本頁(yè)收集關(guān)于如何實(shí)現(xiàn)全文檢索?的相關(guān)信息資訊供網(wǎng)民參考!
  • 推薦文章
    新河县| 五华县| 蓬莱市| 金溪县| 临颍县| 胶州市| 嫩江县| 顺平县| 安新县| 双流县| 枞阳县| 玉山县| 达孜县| 阿鲁科尔沁旗| 莱州市| 玉田县| 平武县| 澄江县| 房产| 元江| 昆明市| 科尔| 柳林县| 滨州市| 开封市| 界首市| 祥云县| 宜城市| 金山区| 孟村| 宣城市| 民勤县| 佛坪县| 南部县| 龙门县| 云霄县| 永胜县| 额尔古纳市| 房产| 炎陵县| 仙桃市|