Home › Forums › Backend Issues (wp-admin) › get_field() – strange behaviour › Reply To: get_field() – strange behaviour
Hi @hube2,
thank you for your reply. I know my english is orrible, I am sorry. Try to better explain myself.
In our local environment (same db as production, same code (GIT), same plugin, etc…):
$values = get_field($field_name, $post_id, false);
it works. It returns an array. On our production it returns false
WTF.
PHP version is just the one difference beetwen environment.
For your information:
$post_id is the current language POST ID, so it is right. We are getting values from the current POST ID and copy it to the translated posts, because we want the same exactly gallery, even if user upload photos to german version (for example) and not into english version.
Best regards
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.