[EventCalendar] Re: Ignore post_date when start set (corrected)
jacob.kennedy at sears.ca
Thu Jul 19 20:01:32 UTC 2007
I'm almost there.
In eventcalendar3.php, function ec3_filter_posts_where(&$where) I changed
the line :
$where.=" AND (($where_post_date) OR ($where_start)) ";
$where.=" AND (($where_post_date AND id NOT IN (SELECT DISTINCT
post_id FROM $ec3->schedule)) OR ($where_start)) ";
and in template-functions.php, function
ec3_util_calendar_days($begin_month_id,$end_month_id) I altered it to look
// We are interested in normal posts, as well as events.
$sql="( $sql ) UNION
( SELECT DISTINCT
post_date AS start_date,
post_date AS end_date,
0 AS allday,
0 AS is_event
AND id NOT IN (SELECT DISTINCT post_id FROM
(the last line is what I added)
Now I've got it filtering exactly as I want it on the calendar and
whenever a date query is performed. The only missing link appears to be
on the home page. I would have thought that it WAS performing a date
query on the home page (something like WHERE post_date <= Now()) but if it
was it should have gone through the filter I altered, right?
I'm on the final leg... any hints?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the EventCalendar