<%if not (member or editor or master) then response.redirect("/common/members_only.asp") end if %> <% Function StandardDate(mDate) mDate = CDate(mDate) StandardDate = Day(mDate) & "/" & Month(mDate) & "/" & Year(mDate) End Function Function nz(mData) ' avoid saving null values If len(mData) = 0 then nz = " " Else nz = mData End if End Function Function ReplaceChar(mChar,mData) If Instr(mData,chr(mChar)) > 0 Then DataLength = len(mData) Pointer = 1 Do While Pointer <= DataLength Char = Mid(mData,Pointer,1) If Char = chr(mChar) then mData = Left(mData,Pointer-1) & " " & Mid(mData,Pointer+1) End If Pointer = Pointer + 1 Loop ' next char in string End If ReplaceChar = mData End Function Function FixApostrophe(mData) If Instr(mData,"'") > 0 Then DataLength = len(mData) Pointer = 1 Do While Pointer <= DataLength Char = Mid(mData,Pointer,1) If Char = "'" then If Mid(mData,Pointer,2) <> "''" then mData = Left(mData,Pointer) & "'" & Mid(mData,Pointer+1) Pointer = Pointer + 1 DataLength = DataLength + 1 End If End If Pointer = Pointer + 1 Loop ' next char in string End If FixApostrophe = mData End Function function WriteSelectCodeSingle(mReq,mText) response.write("") end function function WriteSelectCode(mReq,mTag,mText) response.write("") end function Function ReFormatted(Str) on Error resume next Str=Replace(Str, CHR(13), "") Str=Replace(Str, CHR(10) & CHR(10),"

") Str=Replace(Str, CHR(10), "
") ReFormatted = "

" & Str & "

" End Function Function VetInput(cTestString) ' checks for HTML or profanities in a string ' each 'library!' word is searched for in the string ' if any of the library words are surrounded with text, then the word is passed (eg 'scunthorpe') ' if the word is at the beginning or end of another word, then it is blocked. VetInput = "OK" If (Instr(cTestString,"<") > 0 and Instr(cTestString,"<") > 0) then VetInput = "html" Else Dim aProf,Profanity, Suffix, Prefix,pointer, offset, alphachars aProf = Array("bum","tit","crap","fuck","phuck","tosser","fuk","bollo","cunt","bastard","wank","shit","wank","wog","coon","arse") Profanity = "" alphachars = "abcdefghijklmnopqrstuvwxyzABSDEFGHIJKLMNOPQRSTUVWXYZ" cTestString = " " & cTestString & " " ' insert a space at each end of the string For pointer = 0 To UBound(aProf) - 1 offset = InStr(UCase(cTestString), UCase(aProf(pointer))) If offset > 0 Then Prefix = Mid(cTestString, offset - 1, 1) Suffix = Mid(cTestString, offset + Len(aProf(pointer)), 1) If InStr(alphachars, Prefix) > 0 And InStr(alphachars, Suffix) > 0 Then ' it's embedded in another word, so we'll take a chance Else Profanity = Mid(cTestString, offset, Len(aProf(pointer))) Exit For End If End If Next If Len(Profanity) > 0 Then VetInput = "suspect" 'VetInput = "sorry, your entry contained the word " & Profanity & " and cannot be saved." End If End If End Function %> <%=SiteName%>
Member List

<%if master then %> As you are currently logged in as an NPC master editor, this page enables you to view or search the member & boat lists, and edit, delete, or add member records.
You may also download the membership database as an excel file.
(you will need Microsoft Office on your PC) <%elseif editor then %> As you are currently logged in as an NPC editor, this page enables you to view or search the member & boat lists, and edit existing member records.
You may also download the membership database as an excel file.
(you will need Microsoft Office on your PC) <%else %> You are logged in as an NPC member. This page enables you to view or search the member & boat lists, and make alterations to your own member record. <%end if %>

<%if editor or master then %>
Excel Table Downloads
(each takes about 10 secs via Broadband)
<%elseif member then %> ">edit your own member record <%end if %>
free text search for members:
(surnames, post towns etc.)
" size="30">
or list all members with surnames beginning with: <%if master then %> <%end if %>
<% tblName = "tbl_Members" SearchString = "" FilterString = "" If not (editor or master) then FilterString = " and status = 'active' " select case request("listmode") case "A to D" : SearchString = " where left(surname,1) between 'a' and 'd' " case "E to K" : SearchString = " where left(surname,1) between 'e' and 'k' " case "L to R" : SearchString = " where left(surname,1) between 'l' and 'r' " case "S to Z" : SearchString = " where left(surname,1) between 's' and 'z' " case else if len(request("searchtext")) > 0 then SearchString = " where (surname like '%"+request("searchtext")+"%' or firstname like '%"+request("searchtext")+"%' or address1 like '%"+request("searchtext")+"%'or address2 like '%"+request("searchtext")+"%' or address3 like '%"+request("searchtext")+"%' ) " else SearchStrimg = "" end if end select if len(SearchString) > 0 then SQLString = "SELECT * from "&tblName&SearchString&FilterString&" ORDER by surname" OpenOleConn(datadir&"npc_members.mdb") Set rs = objConn.execute(SQLString) if rs.eof then %>

no members found matching that search criteria <%else %> <%Do While NOT rs.EOF %> <%rs.MoveNext() Loop %>
Member Boats(s) Address Telephone Mobile Email

<%=rs("title")%>  <%=rs("firstname")%> "><%=rs("surname")%>  <% sql2 = "SELECT tbl_member_boat.member_number as member_number, tbl_boats.boat_id as boat_id, tbl_boats.boat_name as boat_name "&_ "FROM tbl_member_boat LEFT JOIN tbl_boats ON tbl_member_boat.boat_id = tbl_boats.boat_id "&_ "where member_number = '"&rs("member_number")&"'" Set rs2 = objConn.execute(sql2) do while not rs2.eof %> "> <%=rs2("boat_name")%> <% rs2.movenext() if not rs2.eof then %>
<% end if loop 'rs2 link file %>
<%=rs("address3")%> <%if not rs("telephone_priv") then response.write(rs("telephone"))%> <%if not rs("mobile_priv") then response.write(rs("mobile"))%> <%if not rs("email_priv") then response.write(rs("email"))%>


<%end if %> <%closedata() end if %>