Views - displaying block content based on event start date
steveadamo - March 31, 2009 - 14:03
I've got a view which shows events occuring at a specific location. I would like to apply a filter, so that the view will only display upcoming events (the block currently shows all events regardless of the date of the event relative to today's date).
I was thinking I would update my custom content type (location event) and add a CCK date field, but thought I would see if there is a way I can expose the "start_date" in the events table, so that I can simply filter by that existing field in my view.
Is that an option? I've been trying a few different approaches in my view (creating relationships, etc., but nothing seems to reveal that start_date as a field I can apply any logic against).

so it looks like i have an
so it looks like i have an option to go with the CCK date field, and use the calendar module as well...
http://drupal.org/project/calendar
but do i really have to go that route just to make my event views smart enough to not display events that have passed their start dates?
_
I'm confused-- if you don't already have a cck date field on the event, how are you recording the date of the event? If you do have a date field, you can add a filter in views and set it to 'greater than or equal to now'.
_
Don't be a Help Vampire - read and abide the forum guidelines.
If you find my assistance useful, please pay it forward to your fellow drupalers.
sorry, let me clarify... i
sorry, let me clarify...
i created a custom content type, and by virtue of simply enabling the event (or was it signup) feature, the form is populated with a "start date" field... thats the start date i referred to in my initial post...
its not a custom CCK field I've added, and as such, i cant seem to find a way to expose, and subsequently filter by that data...
but ive now watched a great video on drupal therapy about the date, calendar, views and cck module combination, and feel fine going forward with that approach... :)
Hello steveadamo, can you
Hello steveadamo,
can you please share with us which video is that? I'd like to solve the same problem!
Thank u
Studenti dell'Università di Macerata UniMc
Here you go...
http://www.drupaltherapy.com/date