Created
April 24, 2016 23:36
-
-
Save AugustMiller/1706dd5d6fc5f36cd99723604d08b1cc to your computer and use it in GitHub Desktop.
Fetch entries with a custom date field set between two other dates
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {% set entriesWithDateInRange = craft.entries({ | |
| section: 'section', | |
| type: 'type', | |
| order: 'customDate asc', | |
| customDate: ['and', '>= ' ~ now, '<= ' ~ (now.year + 1)] | |
| }) %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment