Posted: July 25, 2017 at 8:34 am
|
We are running Version 4.9.44.p After upgrading to this version, our expired events are now showing in our custom event lists (they didn’t used to). I don’t know which version change created this, but I know it was working correctly on Version 4.9.7.p. I can’t find changes relating to this in the Changelog, so I must have missed something. Here is the code, which is based on this page (https://gist.github.com/joshfeck/e3c9540cd4ccc734e755):
Here is the page where you can see this historic expired meetups showing in the upcoming list: And here is a staging site copy that is running Version 4.9.7.p. And you’ll notice that no expired events are showing. (There are no upcoming on that site, so nothing is showing). One of the most recently changelogs indicated that EE_Event_List_Query is deprecated, but I did not see a replacement indicated. Please inform of the way to properly accomplish our code in the new version. |
Hi Adam, You can change this: and that should fix things for you. |
|
|
That corrected the expired events issue, but with that code, the taxonomy query no longer worked. How can I get both the expired events filter and the taxonomy query working at the same time like it was before? |
Event Espresso 4.9.45 is released and includes a fix for the stripped query args. It is available as a 1-click update from your WP Dashboard’s Plugins page. You can trigger an update notice (if you don’t see one yet) by going to the Event Espresso > General Settings page then click on Save. |
|
|
Wonderful – that worked. Thank you! I upgraded to Event Espresso 4.9.45, and implemented your code above, and it’s all working properly again. Out of curiosity, why is EE_Event_List_Query being removed? Having access to that is almost critical to EE development. |
EE_Event_List_Query was deprecated in favor of EventEspresso\core\domain\services\wp_queries\EventListQuery. The Event Espresso 4 codebase is gradually converting over to PSR-4 Autoloading. You can actually use the standard WP_Query class to pull in events in the same manner as the EventListQuery class, the difference being there are a few conveniences with the latter. |
|
The support post ‘Expired Events Showing after Version Upgrades’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.