help on functions instr....
I am writing a function to keep the values between the content class when i search an html page because I just want the text between the content class to be searched, but it keep giving me errors.
iPos = InStr(1,orig_string,"<p class=""content"">")
<%
Function Remove(orig_string)
iPos = InStr(1,orig_string,"<p class=""content"">")
If iPos = 0 then
strTitle = "Untitled"
Else
strTitle = Mid(orig_string,iPos+21,InStr(iPos,orig_string,"<p class=""content"">")-iPos-21)
End If
orig_string=strTitle
End Function
%>
contValue = "<p class=""content"">Monsignor Frank Rossi - Director<p class="content">"
x= remove(contValue)
response.write x
|