MyBB Community Forums

Full Version: Today's birthdays
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Tried searching but with the search-function here leaving a little bit to hope for...couldn't find it...

The list of "today's birthdays" is showing not only today's birthdays but also tomorrows.......(confirmed by clicking on the names on the list and the birthdate in the profile shows tomorrow's date)

Any idea what might be going wrong?

cheers,
kimmo
Is this just happening on today's date but all dates? Are you able to test/change the date and see?
I tried it on today's date and it seems to be fine.

It appears to be fixed for 1.2.
well I only noticed it today when I saw that even for a community of 20,000 people, something like 30-40 birthdays is a little unlikely....
I will check tomorrow as well to see if it starts adding 16th of June as well
yep...the problem is...if nothing else...consitant...continues to show today and tomorrow's bdays...

could this have something to do with timezones? or maybe I have fixed something to pieces?

cheers,
Kimmo
can someone at least point me out where the calculation for the date is being done so I can see if any my customations have screwed up things...
I'm running a myBB forum to organise a paintball trip, it's dead useful for that sort tof thing.

But I'm getting a similar problem, my forum doesn't seem to know what *today* is. when i look at people who have been online today, it merrily lists off all the people who were online today, and those who were online yesterday evening, happily telling me they were online this morning (which they weren't). It seems to just list off the ppl who were online in the last 24hrs, rather than *today*.

Weird Huh?
The code is as follows:

	$bdaydate = mydate("j-n", $bdaytime, "", 0);
	$year = mydate("Y", $bdaytime, "", 0);
	$query = $db->query("SELECT uid, username, birthday FROM ".TABLE_PREFIX."users WHERE birthday LIKE '$bdaydate-%'");

It loads birthdays based on your timezone, so if it is the 12th it'll load birthdays on the 12th.

Quote:But I'm getting a similar problem, my forum doesn't seem to know what *today* is. when i look at people who have been online today, it merrily lists off all the people who were online today, and those who were online yesterday evening, happily telling me they were online this morning (which they weren't). It seems to just list off the ppl who were online in the last 24hrs, rather than *today*.

"Today" is basically synonymous for "the last 24 hours" so it includes everything up until 24 hours ago.
that's a good point actually...now I really want to see the function...could it be done with a calculation on the timestamp...
(Now()-86400000)< birthday < (Now()+86400000)
that would not be good I think.....
oops I was too slow....but I am still wondering why my code then takes TODAY and TOMORROW for Birthdays today.... hmmmm
and now the problem has disappeared...hmmm