Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 809315
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T00:42:32+00:00 2026-05-15T00:42:32+00:00

I have a table in the database which includes all active users. I then

  • 0

I have a table in the database which includes all active users. I then have a user list which needs refreshing to see who is the latest users online.
Whats the best way to tackle this?
The user list is always just who is in the active_users table.
Thanks for reading.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T00:42:32+00:00Added an answer on May 15, 2026 at 12:42 am

    AJAX

    You could use an AJAX request to pull regularly the list of active users and display them on your website.

    You may want to cache that list for a little while on your server in case you have a lot of users requesting it constantly.

    Or, if the list is long, or if you decide to pull a lot of HTML markup with the list, you could also regularly poll your server to check whether there are updates to the (cached…) list since the last time the client updated the list. The reply will be a simple true or false, and the client will only have to request the new list when it has changed.


    Meta refresh tag

    You could also use the meta refresh tag, either to update the entire page, or an iframe if you don’t mind iframes.

    Refresh after one minute:

    <meta http-equiv="refresh" content="60" />
    

    Or with an url:

    <meta http-equiv="refresh" content="60;url=http://site.com/list.php?counter=1" />
    

    Manual update

    Finally, you may just add a button or a simply a link at the end of the list, and the user could decide for herself whether to reload or not.


    Other considerations

    As JoeGeeky pointed out in the comments, for performance and bandwidth reasons, you may want to implement a counter which limits the maximum number of times the user list is loaded. This is valid for Ajax and Meta refresh tags. In javascript you could simply have a variable incrementing every time you load the list, and in case of the meta refresh tag you could add the counter in the url as a get variable.

    Also those three approaches do not exclude each other but should be combined: Use Ajax for the folks with javascript activated, a meta refresh iframe in a noscript tag as a fallback for the ones with javascript disabled (as mentioned by stagas), and a button or link for manual update once the maximum list reload count has been reached.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

So I have a mySQL database with a 'users' table which includes a username,
I have two tables in a database. Table 1 includes an order number which
I have a database with a table which includes among others, one column of
I have a file with all my database variables which includes following line: public
I have one database table which contains 8 columns. One of the columns is
I have a database table which link locations together; a location can be in
I have a database table which is full-text indexed and i use the CONTAINS-function
I have a table (session) in a database which has almost 72,000 rows. I
we have a table in an Oracle Database which contains a column with the
I have a table in a postgresql-9.1.x database which is defined as follows: #

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.