Home › Forums › Bug Reports › Can no longer get raw date field › Reply To: Can no longer get raw date field
More than likely this coincided with changes needed in relation to the new date/time picker. The dashes are added when the field is loaded. It seems from looking at other code in ACF that if the dashes are not there that the value would get confused with a unix time stamp value. I would suggest adding a load_value filter for date fields, but it you did that ACF would probably convert the value to something other than the date entered.
It seems that the only choices you have are to remove the dashes after getting the value or to use get_post_meta($post_id, $field_name, true)
to get the value.
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!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.