Hello,
we've got a page for events where we display the date when the event will start and end.
For example:
In the backend we entered the date from June 9, 2022 to June 11, 2022
but in the frontend it only show the "from date" -> June 9, 2022
Can you tell me what is causing this error?
Thanks in advance!
Hi Lars,
Thank you for getting in touch.
Would you mind allowing me to have admin access to the website so that I can have a more detailed look at this for you ?
Please where applicable please provide me with a link to an example page where I can see the issue.
I've enabled the private fields for your next response.
Thanks,
Shane
Hi Lars,
Thank you for the credentials.
This should now be working. The issue was that you were trying to compare the dates in their text formats rather than the timestamp.
It's much easier to compare as a timestamp since this is a numerical value. Take a look at the conditional below.
[wpv-conditional if=" '[types field='veranstaltung-ende' output='raw'][/types]' gt '[types field='veranstaltung-beginn' output='raw'][/types]' "]
Take not of the output='raw' as this is what is used to display the value that is stored directly in the database. In the case of date fields this raw value would be a timestamp.
Thanks,
Shane
My issue is resolved now. Thank you!