Home › Forums › General Issues › Possible bug with get_field() › Reply To: Possible bug with get_field()
Hi @Icethrill
Unfortunaltey, ACF needs to get past the init action for it to work (get_field / any api function)
I’m hoping to find a work around in the future, but for now if you move your code within an action (init or later), then your value will work as expected!
Sorry for the confusion.
Cheers
E
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.