So I am currently using the 3rd party Date and Time Picker Field addon. With the new 5.3.9 including it into core I would like to switch over to it. I have a bunch of time fields. Looks like with a little revisions to my theme and custom fields I can get it working in the same time format however I haven’t figured out a good solution to handle my old data as the database format appears to be different.
Any suggestions? I assume the cleanest way to handle would be to do a one time batch updates to all of my old fields. I have over 5000 custom post entries each with potential of 8 custom time fields. For now I’m just going to continue using ACF Pro 220.127.116.11 while I work out this database conversion issue on my staging site.
Thanks for the quesiton.
Looks like the 3rd part field is saving the value as a time stamp, whereas ACF saves the value in a human friendly format hh:ii:Ss.
The 2 should be compatible, have you tried loading the old and new values via get_field()? What is the result of each?
I haven’t begun working on the frontend as the backend displays are wrong. Here is what I’m seeing.
In the database the start time field is set to 1465898400.
Thanks for the email.
I’ll do some testing with these setting / values, and get back to you with my findings.
In the meantime, can you please download the latest plugin files from your account online to make sure you have the most up to date timepicker code?
* I made some quick updates to this field post launch
I’ve just made some more improvements with compatibility.
Please read my final reply to this topic:
You must be logged in to reply to this topic.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
📣 “ACF Chat Fridays”— Advanced Custom Fields (@wp_acf) January 31, 2023
The ACF team holds their first open office hours this Friday! Come and talk ACF, and ask questions about building sites with the plugin.
We’d love to see you there!
📆 Friday 3rd Feb - 3pm UTC
👉 Register here - https://t.co/3UtvQbE4CU pic.twitter.com/oTwW9K1XQ0
© 2023 Advanced Custom Fields.