%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%> <% dim count_page dim WordData, word_condition, WrPos, WordIndex Set WordData = New Ark_Data dim word_id, word_title, word_date, word_order, word_display dim search_type dim search_change, word_search, word_array, word_bound, word_len dim word_replace dim url_link dim i word_search = request.QueryString("word_search") search_type = request.QueryString("search_type") word_title = request.QueryString("word_title") url_link = request.QueryString("url_link") if word_title = "" then response.Redirect("Garvey-word.asp" & JAH & id) elseif InStr(word_title,";") > 0 OR InStr(word_title,"@") OR InStr(word_title,"'") then response.Redirect("http://google.com") end if if word_search <> "" then search_change = Replace(word_search, "'", "~^") search_change = Replace(search_change, "'", "~^^") word_array = split(search_change, " ") word_bound = Ubound(word_array) word_len = word_bound + 1 end if dim regexp_link, link_replace Set regexp_link = New RegExp With regexp_link .IgnoreCase = True .Global = True End With if word_title <> "" then word_condition = "word_title = '" & word_title & "'" Set WordData = Ark_DBAccess.DBSelect("marcus_words", "word_title, word_date, word_order, word", word_condition, "word_order") if WordData.DataExists then word_date = WordData.GetFirstItem("word_date") end if end if title="Marcus - " & replace(word_title, "~", "'") page="/jah-index.asp" count_page="Marcus Words|show-garvey-word.cfm" %>
| <%=title%> |
| <%response.Write(FormatDateTime(word_date, 1))%> |
| <%
if WordData.DataExists then
WordIndex = WordData.GetItemIndex("word")
For WrPos= 0 to WordData.UpperBound
word_display = WordData.GetItemByIndex(WordIndex, WrPos)
if word_search <> "" then
if search_type = "one-no space" then
regexp_link.Pattern = "("&search_change&")"
word_display = regexp_link.replace(word_display, "$1")
elseif search_type = "one-space" then
regexp_link.Pattern = "( "&search_change&" )"
word_display = regexp_link.replace(word_display, "$1")
else
for i = 0 to word_bound
if search_type = "multiple-no space" then
regexp_link.Pattern = "("&word_array(i)&")"
word_display = regexp_link.replace(word_display, "$1")
elseif search_type = "multiple-space" then
regexp_link.Pattern = "( "&word_array(i)&" )"
word_display = regexp_link.replace(word_display, "$1")
end if
Next
end if
end if
word_display = replace(word_display, chr(10), " ") word_display = replace(word_display, chr(13), " ") word_display = Replace(word_display, "~", "'") response.Write(word_display) Next End If %> |