Home › Forums › Backend Issues (wp-admin) › Import published post year to acf field › Reply To: Import published post year to acf field
Hi @kollinsayz
I’m not sure what you mean when you say “based on the already existing posts”
You could use the acf/load_value filter to pre-populate the value a field.
Here’s the PHP manual for getting the current date/time.
But remember that WordPress time stamps posts automatically, and you can use the Date Parameters of a WP_Query to show posts associated with a certain time and date period.
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.