Print Page | Close Window

display whos online on default.asp

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=2923
Printed Date: 01 April 2026 at 6:54am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: display whos online on default.asp
Posted By: 8ball
Subject: display whos online on default.asp
Date Posted: 21 May 2003 at 2:36pm

Ok, Im sure it's already been asked, but I searched and cant find my answer. I would like to display the names of who's online right on my default.asp.

something like:

users online: sexygirlthatwants8ball, sexygirlssisterthatwants8ball etc...

heehe anyone?

thx




Replies:
Posted By: Allan_Young
Date Posted: 21 May 2003 at 5:14pm

I know there was a MOD for this, but I can't find it!

Copied the code from my navigation_bottons page as follows - view it working at http://www.nwcld.org/index2.htm - http://www.nwcld.org/index2.htm  (please let me know what you think)

Active
                  members: </span>
                  <%
Dim rsActiveMemberName
Dim strMemberName
Dim rsActiveUsers
Dim strRedTextColour
Dim strProfileWindowWidth
Dim strProfileWindowHeight

'Intialise the ADO recordset object
Set rsActiveUsers = Server.CreateObject("ADODB.Recordset")

'Initialise the SQL variable with an SQL statement to get the configuration details from the database
strSQL = "SELECT tblActiveUser.* FROM tblActiveUser WHERE NOT tblActiveUser.Author_ID = 2;"
 
'Query the database
rsActiveUsers.Open strSQL, strCon

If NOT rsActiveUsers.EOF Then
 Do Until rsActiveUsers.EOF
  Set rsActiveMemberName = Server.CreateObject("ADODB.Recordset")

  strSQL = "SELECT tblAuthor.* FROM tblAuthor WHERE tblAuthor.Author_ID = " & rsActiveUsers("Author_ID") & ";"
 
  rsActiveMemberName.Open strSQL, strCon

  If NOT rsActiveMemberName.EOF Then
   strMemberName = ("<font color=""#FF0000"">></font><a href=""javascript:openWin('pop_up_profile.asp?PF=" & rsActiveUsers("Author_ID") & "','profile','toolbar=0,location=0,status=0,menubar=0,scrollbars=1,resizable=1,width=590,height=425')"" class=""smltext"">") & rsActiveMemberName("Username") & ("</a>")
  End If
%>
                  <% = strMemberName %>
                  &nbsp;
                  <% 
 rsActiveUsers.Movenext
 Loop

'Reset server objects
rsActiveMemberName.Close
Set rsActiveMemberName = Nothing

End If
%>



-------------
Everyone has a photographic memory, its just that some are out of film


Posted By: fernan82
Date Posted: 21 May 2003 at 8:06pm
you also want to add AND tblActiveUser.Hide = 0; on your sql query, that way if the users doesn't add himself to the active users list it won't show.

-------------
FeRnAN
http://www.danasoft.com/">


Posted By: Allan_Young
Date Posted: 22 May 2003 at 2:21am

Which sql query should I make the change on please?

The code above was a MOD which I included and changed a bit, only changed the bits I knew about!

Thanks



-------------
Everyone has a photographic memory, its just that some are out of film


Posted By: Scotty32
Date Posted: 22 May 2003 at 4:44am

doesnt MadDog have this on his site?

or is that where ya got it from?



Posted By: Allan_Young
Date Posted: 22 May 2003 at 5:33am
I did originally say it was from a published MOD, couldn't actually remember where it came from, so appologies if I have upset anyone.

-------------
Everyone has a photographic memory, its just that some are out of film



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net