<p>I fear this is not possible with a simple <code>postDate</code> parameter and you have to find a workaround.
The Twig apporach would be to loop all events and filter the right ones with a simple conditional.</p>

<pre><code>{% set events = craft.entries.section('events').limit(null).order('postDate asc') %}
{% for event in events %}
    {% if event.postDate|date('m-d') == now|date('m-d') %}
        ...
    {% endif %}
{% endfor %}
</code></pre>

<p>If you'd like to paginate the results, collect / merge entry IDs within the for loop first and
then prepare another ElementCriteriaModel with these IDs in its <code>id</code> param, to get the entries.</p>

CC BY-SA 3.0
2015-05-29T15:39:00.340Z
2015-05-29T15:39:00.340Z
carlcs
<p>A project I'm working on needs to show a daily reading depending on the date you access the page. I plan to create entries for each day of the year, and each year it will show the post for that day.</p>

<p>For example, I'll create an entry with a post date of May 1, 2015. That entry should show on May 1, 2016/2017/2018, etc.</p>

<p>I've tried only putting in MM-DD in the postDate parameter, but no luck; that throws a PHP error. Any ideas?</p>

<entries><postdate>
Show entry on certain date, regardless of year
# Show entry on certain date, regardless of year

(Asked by: username_0 on 2015-05-29)

A project I'm working on needs to show a daily reading depending on the date you access the page. I plan to create entries for each day of the year, and each year it will show the post for that day.

For example, I'll create an entry with a post date of May 1, 2015. That entry should show on May 1, 2016/2017/2018, etc.

I've tried only putting in MM-DD in the postDate parameter, but no luck; that throws a PHP error. Any ideas?

**Tags:** entries, postdate

---

## 1 answers

### Answer by username_1 on 2015-05-29. Score: 1 | Accepted answer

I fear this is not possible with a simple postDate parameter and you have to find a workaround.
The Twig apporach would be to loop all events and filter the right ones with a simple conditional.
{% set events = craft.entries.section('events').limit(null).order('postDate asc') %}
{% for event in events %}
    {% if event.postDate|date('m-d') == now|date('m-d') %}
        ...
    {% endif %}
{% endfor %}

If you'd like to paginate the results, collect / merge entry IDs within the for loop first and
then prepare another ElementCriteriaModel with these IDs in its id param, to get the entries.


---

