<% Option Explicit Dim sql,username,rsUser,rsMessages,newcount username = Request.Cookies("username") 'If the username cookie is set, they must have logged in, so get their details from the database if username <> "" then %> <% sql = "SELECT icon FROM Users WHERE username = '" & username & "'" Set rsUser = Server.CreateObject("ADODB.Recordset") rsUser.Open sql, conn, 3, 3 sql = "SELECT messageread FROM messages WHERE sendto = '" & username & "'" Set rsMessages = Server.CreateObject("ADODB.Recordset") rsMessages.Open sql, conn, 3, 3 newcount = 0 if not rsMessages.EOF then rsMessages.Movefirst do until rsMessages.EOF if rsMessages("messageread") = False then newcount = newcount + 1 end if rsMessages.Movenext loop rsMessages.Movefirst end if end if %> FRIENDS

 

 

Welcome
Articles
Downloads
Favorites
Feedback
Friends
Interests
Multimedia
Photos

Friends

WELCOME FRIENDS!

<%'If they're not logged in, then display a login box if username = "" then%> <%'If they are, show a mini profile box plus a sign out link else%> <% rsUser.close set rsUser = nothing rsMessages.close set rsMessages = nothing conn.close set conn = nothing end if %>
SIGN IN
Username :
Password :
Remember me :

I am not a user so
sign me up!
Welcome Back!
.gif" width=50 height=50 align="right"> Welcome <%=username%>.
View/Edit Profile
My Inbox (<%=newcount%> new)
View Userlist
Sign Out

If you're not already logged in, please do so.  If you're not a member, why not?  Sign up, it's free, and I have a lot of things on the horizon for the friends section.  Feel free to join and get to know present and future friends.

Checking the "Remember Me" checkbox ensures you are kept logged in even when the browser is closed. Leaving this unchecked keeps you logged in only for the duration of the browser session.

 

Admin