How many users online in the last 24-hours using time()?


Posted on 16th Feb 2014 07:03 pm by admin

I'm fairly new to PHP. I have a MySQL table called 'users' and a field called 'loggedin' which is in time() format.

I need a query that'll check how many players have logged in within the last 24-hours, but I'm not sure where to start. I already have the database connection setup, and just need the amount to be set to "$online24h"

Can anyone help me please?

No comments posted yet

Your Answer:

Login to answer
253 Like 25 Dislike
Previous forums Next forums
Other forums

serializing objects - loses methods - the point being?
Hi

I know that serializing an object will lose the methods. But whats the point in that? What

Beginner question regarding Array's
Hi everyone, the page im working on has an array of variable at the top...

Code: $define_li

PHP Form to Variable.
Hi! I have written a HTML-form code in DreamWeaver CS3 (in a PHP doc) and I really need it to work s

PHP Code To Change Font Color in Table Cell
I would appreciate help with the following snippet of my php code. I am just trying to change the f

PHP webpage & array print issue
I have this code running, and it works perfectly … however, see my bottom bit about what I see

Problem!
I have another problem, when i run this code i get this error "Parse error: syntax error, unexp

Preserving user-entered linebreaks
Hi, I'm building a web 2.0 thingy from scratch and I wanna display text which users input. It's all

DataTable Help Required
Hi all I am creating an app that utilises and MS Access back end and queries it quite a bit at vario

How to search for several parameters from objects in a database?
I have a database with lots of information about objects.
Now I would like to search for 4 or 5 p

Access website from only 1 computer...?
One of my customers wants his website to only be accessed by people in which they bought the website

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash