## ACF: If field contain a specific value, update value in another field programatically

Question

how can I change the value of a field based on the value of another field programatically?

This other field has already a value but I need to replace / update it.

To be more precise:

If the Text Field named type has value Houses AND another Text Field named service has value 2, this should be updated in NOT AVAILABLE.

Or …

If the Text Field named type has value Parks AND another Text Field named service has value 2, this should be updated in AVAILABLE.

Or …

If the Text Field named type has value Store AND another Text Field named service has value 2, this should be updated in COMING SOON.

I read the update_field doc but I could not solve this.

0
4 months 2022-05-01T15:38:48-05:00 0 Answers 0 views 0