Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - IIS indexing services search
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

IIS indexing services search

 Post Reply Post Reply
Author
mar0364 View Drop Down
Newbie
Newbie


Joined: 13 December 2003
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote mar0364 Quote  Post ReplyReply Direct Link To This Post Topic: IIS indexing services search
    Posted: 20 December 2003 at 4:08pm

May not be the right place to ask this question. Thought I'd give it a shot. I've gotten the search to work. Im having trouble getting the links to ASP pages to work. Its got something to do with the way I'm reading the server address to the page(i think).

Here is an example
Link to page from browser address bar:
http://rehab_test/estate_mangement.asp

Link to same page from search results:
file://fldoiremrhbfp4/intranet/test/intranet/estate_mangemen t.asp

Here is the code used to read the results to the page.

<%
Dim strSearch

Set rsSearch = Server.CreateObject("ADODB.Recordset")

' create the connection string
strConn = "Provider=MSIDXS; Data Source=Rehab_Test"

' Build our Query: Hide admin page and FPSE pages
strQuery = "(" & strQuery & ")" _
& " AND NOT #filename = *admin*" _
& " AND NOT #path *\_vti_*"


' construct the search string
strSearch = "SELECT DocTitle, Path, FileName, Characterization, Size" & _
" FROM SCOPE ()" & _
" WHERE CONTAINS ('" & Request.Form("txtSearchFor") & "')"

' open the recordset on the search
rsSearch.Open strSearch, strConn

' show what's been searched for
While Not rsSearch.EOF
Response.Write "<SPAN CLASS='document'>" & rsSearch("DocTitle") & "</SPAN><BR>" & _
rsSearch("Characterization") & "<BR>" & _
"<A HREF='" & rsSearch("Path") & "'>" & rsSearch("FileName") & "</A>" & _
" (" & rsSearch("Size") & " bytes)<P>"
rsSearch.MoveNext
Wend
Function PathToVpath(strPath)
Const strWebRoot = "d:\intranet\live\"

Dim strTemp

strTemp = strPath

strTemp = Replace(strTemp, strWebRoot, "\")
strTemp = Replace(strTemp, "\", "/")

PathToVpath = strTemp
End Function

' tidy up
rsSearch.Close
Set rsSearch = Nothing
%>

Thanks for any help you can give.

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.