The Context module lets you alter things like the blocks that display on a page based on conditions that you set. The current conditions include things like checking the content type of a node. There are lots of times it would be useful to have a way to set a condition based on the value of a date field. For example, if you have an event content type you might want to display different blocks on the page depending on whether the event is still in the future or if it has passed.

I need this functionality and am adding a Date condition plugin as an optional module. It works similarly to the way Date filters work -- you select a date field, an operation, and a value to do things like test if the field contains a value that is >= 'now'. If it meets the test, whatever you set up in the reaction will happen on that page, otherwise it will not.

Comments

karens’s picture

Status: Active » Fixed

And this has been committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

ACF’s picture

Hi KarenS,

This is exactly what I need, is there any chance you could post something on how to get this to work. I have the most recent versions of date and context for d7.

Thanks

Anonymous’s picture

Hi all

For me the same :-(

I can't see the "date" context option :-(

Best regards
ArchGalileu

pacome’s picture

You have to check it in the module page, under the "date" section
-p-