Quote:
Originally Posted by JimboSlice
doesnt show todays events, only future.
|
Quote:
Originally Posted by Mark4865
Is there a way to get the event to still show on the day it is taking place and only go away the day after
|
I think there is an error in the SQL query. It needs greater than or equal and less than or equal operators to include the current day, and the part for ranged events the operators were the wrong way round.
Try replacing the query with this:
Code:
$query = sprintf("SELECT * FROM ".TABLE_PREFIX."event WHERE visible = 1 AND (dateline_from >= '%1\$d' || ( dateline_from <= '%1\$d' AND dateline_to >= '%1\$d' ) || (dateline_to = 0 AND DATE(FROM_UNIXTIME(dateline_from)) = DATE(FROM_UNIXTIME(%1\$d)))) ORDER BY dateline_from ASC LIMIT %2\$d",TIMENOW,$show_count);
This should display all day events before and on the day they are happening, and ranged events before and WHILE they are happening.
Alex