Jump to content

Event Calendar - Event Expires Early


sintax63

Recommended Posts

OK, so perhaps "early" isn't as correct as that the event gets removed from my calendar at 12:01 am the day it happens. Is there any way to alter my code to do a "expire the day after" or better yet, expire the time the event happens on said day?

 

$query="SELECT *, DATE_FORMAT( `date`, '%m/%d' ) AS displayDate FROM calendar 
WHERE status='1' AND `date` >= NOW() ORDER BY date ASC LIMIT 5";

 

Any help would be greatly appreciated!  ;D

Link to comment
https://forums.phpfreaks.com/topic/106671-event-calendar-event-expires-early/
Share on other sites

If you use both time and date, then you should use a datetime field to make it easy on yourself.

 

I use Unix Timestamps myself.

 

I'm using date (0000-00-00) and time (00:00:00) in two separate fields.

 

I'm guessing that I would need to redo my databases to use the datetime solution you posted?  :-\

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.