Skip Navigation

[Resolved] Date between not working

This support ticket is created 4 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 4 replies, has 2 voices.

Last updated by rohanA-2 4 years, 5 months ago.

Assisted by: Minesh.

Author
Posts
#1986383
Search.png
Custom FIeld Filter.png

Tell us what you are trying to do?
I have a Type - Checkin which has a custom field checkin date (format-DATE). I am trying to provide a search for administrators to search for individuals who have checked in between a date range.

Is there any documentation that you are following?
Followed the documentation provided but it's still not working. I have attached a screenshot of the Custom Field Filter and the Search Properties. In the search filter I've tried using Type of control (As defined in types/Date), Compare value as a (Date/number), Using this comparison (between).

I've added the url param below once the search button is clicked:
hidden link

All the other filters on the page are working. When I add only the min date filter it provides me all the data. When I add a max filter only, it doesn't show me anything.

Any help would be appreciated.

#1986407

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Can you please share admin access details so I can review the custom search configurations and check whats going wrong with your setup.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#1986427

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

It seems you have imported the data to your custom fields - is this correct?

The thing is that Types date field stores the date value as Unix Timestamp , so when you import the data to Types date field, the date value should be imported as Unix Timestamp.

If you see the following post:
- hidden link

The checkin date shows as today's date and just below it you will notice that the value for the field "wpcf-checkin-date" is shows as date i.e. 2021-03-08 03:54:12.

So, can you import the date values as Unix Timestamp and make sure that the checkin data custom field shows the correct date value instead of today's date.

#1988341

Hi Minesh,

Thanks for that, makes sense. I thought it would be a simple resolution.

I'm passing the date field from Gravity Forms through the Advanced Post Creation. I have a hidden field with a default value of the current date. I've tried using multiple methods I've researched on forums.
1. https://toolset.com/forums/topic/gravity-forms-date-field-compatibility-issue/?bbp_reply_to=1200242&_wpnonce=37e3da873e#new-post
2. https://toolset.com/forums/topic/convert-gravity-forms-date-to-unix-timestamp-to-save-in-toolset-date-field/
3. https://toolset.com/forums/topic/gravity-forms-pass-date-value-to-date-format-custom-fields-unix-format/
4. hidden link

But nothing seems to work.

Any help would be amazing right now.

#1988351

My issue is resolved now. Thank you!