Support

Home Forums Event Espresso Premium Filter on event start date in url

Filter on event start date in url

Posted: March 12, 2019 at 5:08 am

Viewing 1 reply thread


rsthrive

March 12, 2019 at 5:08 am

Hi All,

I was wondering if if would be possible to modify this url to filter on the start date so that any events that have already been started are not returned.

/events?calculate=image_large&include=Term_Taxonomy.Term.slug,Datetime,Datetime.Ticket,Datetime.DTT_EVT_start&order_by[Datetime.DTT_EVT_start]=DESC&limit=50

Many thanks


Josh

  • Support Staff

March 12, 2019 at 7:48 am

Hi,

You can add the following to the url:

&where[Datetime.DTT_EVT_start][]=>&where[Datetime.DTT_EVT_start][]=
then add the current date & time, formatted and urlencoded. For example if you’re using PHP to build the url, you could use this to get/format the date & time:

<?php urlencode(date("Y-m-d H:i:s")); ?>

Viewing 1 reply thread

The support post ‘Filter on event start date in url’ 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