Home › Forums › Feedback › update_field() clarification › Reply To: update_field() clarification
You can get the field key in the admin where you create the fields, you can show them under screen options.
I generally do not have an issue with live/staging/dev because my field keys are always the same in all environments. I guess this depends on how you transfer data between them.
It could be possible, using code to get the correct field reference after the post is created, but it’s not all that easy and would take a lot of resources/db queries to achieve, and it would be specific to the version of ACF you’re using (4 or 5)
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!
🚨 The 2023 ACF Annual Survey closes tomorrow! This is your last chance to complete the survey and help guide the evolution of ACF. https://t.co/0cgr9ZFOJ5— Advanced Custom Fields (@wp_acf) May 18, 2023
© 2023 Advanced Custom Fields.