Hiding based on ACF date
-
I’d like to be able to check the current date and compare it against an ACF date field on a page. If the current date is greater than the one selected from ACF then hide the item. This is how I currently have it setup: https://share.getcloudapp.com/OAuQjyK9 — however it is not working. I read in another thread here to set the date to U but still not working. I’m not trying to do date between, but rather whatever the current date is sa the check. Any suggestions?
Edit: Got it working for anyone attempting this, I had to also change the date to U for the dynamic tag: https://share.getcloudapp.com/lluNdlDZ and changed it from ‘text’ to ‘string to time’ as the comparison. Now with debug it shows the two unix timestamps to compare against: https://share.getcloudapp.com/eDuy7D1P
- The topic ‘Hiding based on ACF date’ is closed to new replies.