Support

Home Forums Event Espresso Premium Extending EE_Event_List_Query class

Extending EE_Event_List_Query class

Posted: December 11, 2015 at 6:52 am


internetmotors

December 11, 2015 at 6:52 am

Hi,
I’ve added some (acf) custom fields and taxonomies to my espresso_events cpt, and now I need to define my custom methods to retrieve events.
I wants to extend the espresso_EE_Event_List_Query class, but it retrieve lots of fatal error, because of Event espresso doesn’t seem to been fully loaded.
Here an expample of error I get:

Fatal error: Call to a member function is_set() on a non-object in /wp-content/plugins/event-espresso-core-reg/core/helpers/EEH_Event_Query.helper.php on line 153

What I’m doing wrong? When I have to include my extending class?

Thanks
Eduardo


Josh

  • Support Staff

December 11, 2015 at 7:56 am

Have you tried loading your code on a later hook point to ensure the class you’re trying to extend has been loaded?


internetmotors

December 11, 2015 at 7:58 am

yes, I’ve tried with no result. As a workaround I’m using the method espresso_get_events().


Josh

  • Support Staff

December 11, 2015 at 8:05 am

If you tried a later hookpoint with no result, that might mean you need an even later hookpoint.

The support post ‘Extending EE_Event_List_Query class’ 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.

Event Espresso