Støv, fibre og metalliske partikler kan påvirke både uptime, levetid og driftssikkerhed. Derfor arbejder flere datacentre systematisk med contamination control.
'------------------------------------- 'SØKER I DOKUMENTER START '------------------------------------- Set adoRs = CreateObject("ADODB.Recordset") adoRs.CursorLocation = adUseClient adoRs.PageSize = recordsToShow adoRs.CacheSize = recordsToShow
Select Case UBound(strKeyword) Case 0 adoRs.Open "SELECT DocID, DocMenuTitle,DocLink,DocLinkUrl,DocLinkTarget,DocTitle,DocContent,DocCreated FROM tblWPDocuments Where DocMenuTitle LIKE '%" & strKeyword(0) & "%' OR DocTitle LIKE '%" & strKeyword(0) & "%' OR DocContent LIKE '%" & strKeyword(0) & "%' ORDER BY DocCreated DESC", adoCn, adOpenForwardOnly, adLockReadOnly, adCmdText Case 1 adoRs.Open "SELECT DocID, DocMenuTitle,DocLink,DocLinkUrl,DocLinkTarget,DocTitle,DocContent,DocCreated FROM tblWPDocuments Where DocMenuTitle LIKE '%" & strKeyword(0) & "%' OR DocMenuTitle LIKE '%" & strKeyword(1) & "%' OR DocTitle LIKE '%" & strKeyword(0) & "%' OR DocTitle LIKE '%" & strKeyword(1) & "%' OR DocContent LIKE '%" & strKeyword(0) & "%' OR DocContent LIKE '%" & strKeyword(1) & "%' ORDER BY DocCreated DESC", adoCn Case 2 adoRs.Open "SELECT DocID, DocMenuTitle,DocLink,DocLinkUrl,DocLinkTarget,DocTitle,DocContent,DocCreated FROM tblWPDocuments Where DocMenuTitle LIKE '%" & strKeyword(0) & "%' OR DocMenuTitle LIKE '%" & strKeyword(1) & "%' OR DocMenuTitle LIKE '%" & strKeyword(2) & "%' OR DocTitle LIKE '%" & strKeyword(0) & "%' OR DocTitle LIKE '%" & strKeyword(1) & "%' OR DocTitle LIKE '%" & strKeyword(2) & "%' OR DocContent LIKE '%" & strKeyword(0) & "%' OR DocContent LIKE '%" & strKeyword(1) & "%' OR DocContent LIKE '%" & strKeyword(2) & "%' ORDER BY DocCreated DESC", adoCn Case Else adoRs.Open "SELECT DocID, DocMenuTitle,DocLink,DocLinkUrl,DocLinkTarget,DocTitle,DocContent,DocCreated FROM tblWPDocuments Where DocMenuTitle LIKE '%" & strKeyword(0) & "%' OR DocMenuTitle LIKE '%" & strKeyword(1) & "%' OR DocMenuTitle LIKE '%" & strKeyword(2) & "%' OR DocTitle LIKE '%" & strKeyword(0) & "%' OR DocTitle LIKE '%" & strKeyword(1) & "%' OR DocTitle LIKE '%" & strKeyword(2) & "%' OR DocContent LIKE '%" & strKeyword(0) & "%' OR DocContent LIKE '%" & strKeyword(1) & "%' OR DocContent LIKE '%" & strKeyword(2) & "%' ORDER BY DocCreated DESC", adoCn End Select
'------------------------------------- 'SØKER I NYHETER START '------------------------------------- Set adoRs = CreateObject("ADODB.Recordset") adoRs.CursorLocation = adUseClient adoRs.PageSize = recordsToShow adoRs.CacheSize = recordsToShow
Select Case UBound(strKeyword) Case 0 adoRs.Open "SELECT NewsID,NewsTittel,Ingress,Regdato FROM tblWPNews Where NewsTittel LIKE '%" & strKeyword(0) & "%' OR Ingress LIKE '%" & strKeyword(0) & "%' OR BrodTekst LIKE '%" & strKeyword(0) & "%' ORDER BY RegDato DESC", adoCn, adOpenForwardOnly, adLockReadOnly, adCmdText Case 1 adoRs.Open "SELECT NewsID,NewsTittel,Ingress,Regdato FROM tblWPNews Where NewsTittel LIKE '%" & strKeyword(0) & "%' OR NewsTittel LIKE '%" & strKeyword(1) & "%' OR Ingress LIKE '%" & strKeyword(0) & "%' OR Ingress LIKE '%" & strKeyword(1) & "%' OR BrodTekst LIKE '%" & strKeyword(0) & "%' OR BrodTekst LIKE '%" & strKeyword(1) & "%' ORDER BY RegDato DESC", adoCn Case 2 adoRs.Open "SELECT NewsID,NewsTittel,Ingress,Regdato FROM tblWPNews Where NewsTittel LIKE '%" & strKeyword(0) & "%' OR NewsTittel LIKE '%" & strKeyword(1) & "%' OR NewsTittel LIKE '%" & strKeyword(2) & "%' OR Ingress LIKE '%" & strKeyword(0) & "%' OR Ingress LIKE '%" & strKeyword(1) & "%' OR Ingress LIKE '%" & strKeyword(2) & "%' OR BrodTekst LIKE '%" & strKeyword(0) & "%' OR BrodTekst LIKE '%" & strKeyword(1) & "%' OR BrodTekst LIKE '%" & strKeyword(2) & "%' ORDER BY RegDato DESC", adoCn Case Else adoRs.Open "SELECT NewsID,NewsTittel,Ingress,Regdato FROM tblWPNews Where NewsTittel LIKE '%" & strKeyword(0) & "%' OR NewsTittel LIKE '%" & strKeyword(1) & "%' OR NewsTittel LIKE '%" & strKeyword(2) & "%' OR Ingress LIKE '%" & strKeyword(0) & "%' OR Ingress LIKE '%" & strKeyword(1) & "%' OR Ingress LIKE '%" & strKeyword(2) & "%' OR BrodTekst LIKE '%" & strKeyword(0) & "%' OR BrodTekst LIKE '%" & strKeyword(1) & "%' OR BrodTekst LIKE '%" & strKeyword(2) & "%' ORDER BY RegDato DESC", adoCn End Select
If CInt(currentPage) <> CInt(totalPages) Then Response.Write "<a href=""" & Request.ServerVariables("SCRIPT_NAME") & "?currentPage=" & currentPage + 1 & "&q=" & Server.URLEncode(Request.QueryString("q")) & """>Neste</a>" Else Response.Write "<u style=""color : silver;"">Neste</u>" End If
Else Response.Write "<b>Beklager, ingen treff i nyheter.</b><br>Kontroller at du har stavet riktig." & vbcrlf End If '------------------------------------- 'SØKER I NYHETER SLUTT '-------------------------------------
Set adoRs = Nothing %> <br><br>
I denne koden så highlighter den kun den som er i strSearchWithin Jeg vil at jeg skal kunne kalle opp en funksjon.
Takk for hjelpen! Behold pointene. Jeg har gitt Keysersoze point også!
Synes godt om
Ny brugerNybegynder
Din løsning...
Tilladte BB-code-tags: [b]fed[/b] [i]kursiv[/i] [u]understreget[/u] Web- og emailadresser omdannes automatisk til links. Der sættes "nofollow" på alle links.