<% dim strOnlyOnline, strOnlyPhotos, i, j, strPageNos 'if not session("IsMemberLoggedIn") then session("redir")="qsearch.asp":response.Redirect "login.asp" if session("redir") <> "" then session("redir") = "" 'Finds Profiles based on the parameters selected by the user... Function GetSearchResults set RS = Server.CreateObject("ADODB.Recordset") set RS1 = server.CreateObject("ADODB.Recordset") set RS2=server.CreateObject("ADODB.Recordset") strMember = request.Form("txtsearch") if strMember="" then GetSearchResults = "
No Profiles found matching your Search
" exit function end if if session("userid")<>"" then strUserSQL = strUserSQL & "and u.user_id_pk<>" & session("UserID") & " and u.user_id_pk not in (select user_id_fk from Tbl_UserFlaggedProfiles where favblockuser_id_fk=" & session("UserID") & " and FavBlockFlag='B')" else strUserSQL = "" end if strSQL = "SELECT distinct U.User_ID_PK, U.username, P.ShortDescription,P.DOB, P.Gender, P.Online,P.logintime, PR.PreferenceDesc FROM (tbl_profiles P inner join tbl_user U on P.user_id_fk=U.user_id_pk) left outer join tbl_Preferences pr on P.ZodiacSign=pr.Prefer_ID_PK WHERE U.Active=true and U.user_id_pk=P.User_ID_FK " & strUserSQL & " and P.ShowProfile=true and P.ClosedProfile=false" '' strSQL = "SELECT distinct U.User_ID_PK, U.username, P.ShortDescription, P.DOB, P.Gender, P.Online, PR.PreferenceDesc FROM tbl_user AS U, tbl_profiles AS P, tbl_preferences AS PR WHERE u.user_id_pk=p.User_ID_FK " & strUserSQL & " and p.ShowProfile=true and p.ClosedProfile=false" 'strSQL = "SELECT u.User_ID_PK, U.username, P.ShortDescription, P.DOB, P.Gender, P.Online, PR.PreferenceDesc FROM tbl_user AS U, tbl_profiles AS P, tbl_preferences AS PR WHERE year(p.DOB) between '" & year(now) - Request.Form("cmbToAge") & "' and '" & year(now) - Request.Form("cmbFromAge") & "' and u.user_id_pk=p.User_ID_FK " & strUserSQL & " and pr.Prefer_ID_PK=p.ZodiacSign and p.ShowProfile=true and p.ClosedProfile=false" strSQL = strSQL & " and u.LoginName='" & strMember & "'" 'u.UserName FOUND# rs.Open strSQL,cn,3,1 strRet = "" 'response.Write(strSQL):response.End If not (rs.BOF or Rs.EOF) then rs.PageSize=10 if request("pg")<>"" then if not rs.PageCount1 then For i = 1 to rs.PageCount if i=rs.AbsolutePage then strPageNos = strPageNos & " " & i & "" else strPageNos = strPageNos & " " & i & "" end if Next end if For j = 1 To rs.PageSize 'while not rs.EOF strRet = strRet & "" & chr(13) strRet = strRet & "" & chr(13) strRet = strRet & "" & chr(13) strRet = strRet & "" & chr(13) strRet = strRet & "
" & chr(13) strRet = strRet & "" & chr(13) strRet = strRet & "" & chr(13) 'photos rs1.Open "SELECT Photo, Priority FROM tbl_userphotos WHERE user_id_fk=" & rs("User_ID_PK") & " and priority=1 and approval='A'",cn,3,1 if not (rs1.BOF or rs1.EOF) then strRet = strRet & "" & chr(13) else strRet = strRet & "" & chr(13) end if rs1.Close strRet = strRet & "" & chr(13) if rs("ShortDescription")<>"" then strRet = strRet & "" & chr(13) else strRet = strRet & "" & chr(13) end if if rs("gender")="M" then if rs("PreferenceDesc") <> "" then strRet = strRet & "" else strRet = strRet & "" end if else if rs("PreferenceDesc") <> "" then strRet = strRet & "" else strRet = strRet & "" end if end if if session("UserID") <> "" then RS2.open "select * from Tbl_UserContacts where User_ID_FK="& session("UserID")& "and ContactUser_ID_FK="&rs("User_ID_PK"),cn,3,2 if RS2.eof <>true then strRet = strRet & "" & chr(13) end if RS2.close end if strRet = strRet & "" if rs("Online") then strRet = strRet & "" if session("IsMemberLoggedIn") = true or session("Userid")<>"" then strRet = strRet & "" & chr(13) else strRet = strRet & "" & chr(13) end if strRet = strRet & "" & chr(13) strRet = strRet & "

" strRet = strRet & "  Enlarge

Request Photo
" & rs("username") & "
" & SafeLayout(rs("ShortDescription")) & "
" & trim(rs("ShortDescription")) & "
" & rs("PreferenceDesc") & ", Male, " & year(now) - year(rs("DOB")) & " years
Male, " & year(now) - year(rs("DOB")) & " years
" & rs("PreferenceDesc") & ", Female, " & year(now) - year(rs("DOB")) & " years
Female, " & year(now) - year(rs("DOB")) & " years Profile already contacted
Recent Visit : " & formatdatetime(rs("logintime"),2)&"OnlineView Profile
View Profile 
" & chr(13) strRet = strRet & "

" & chr(13) Rs.MoveNext if rs.EOF then exit for next else GetSearchResults = "
No Profiles found matching your Search
" rs.Close set rs1 = nothing set rs = nothing exit function end if strRet = strRet & "" & strPageNos & "" GetSearchResults = strRet rs.Close set rs1 = nothing set rs = nothing End Function Function SafeLayout(strArg) 'this code will make the descriptions safe so that it wont affect the layout... dim spccnt,icut,strSDesc,strSDesc1 icut = 1 spccnt = 1 strSDesc = strArg strSDesc1 = "" for icut = 1 to len(strSDesc) if mid(strSDesc,icut,1)=" " then if spccnt=33 then strSDesc1 = strSDesc1 & "
" spccnt = 1 else spccnt = 1 end if else if spccnt=33 then strSDesc1 = strSDesc1 & "
" 'strSDesc1 = mid(strSDesc,1,icut) & " " & mid(strSDesc,icut+1) spccnt = 0 end if end if strSDesc1 = strSDesc1 & mid(strSDesc,icut,1) spccnt = spccnt + 1 next SafeLayout = strSDesc1 End Function %>

Services
<%=fnheader%>


Search by Member ID
 


<%if session("IsFYFMember")= true or session("userid")<>"" then%> <%end if %>
<%=links()%><%=fnsubmenu("Search")%>
Kindly submit yours and your partners personal details. Your Compatibility Report will be sent to you within 5 days from submission.

Search by Member ID
<% if request.QueryString("mode") ="search" then response.Write "
Search Results

" response.Write GetSearchResults end if %>

Member ID

        

<% if session("userid")<>"" or session("username") <>"" then%>
<%end if%>