Home › Forums › Bug Reports › acf/prepare_field not disabling if coupled with conditional logic › Reply To: acf/prepare_field not disabling if coupled with conditional logic
Conditional logic does two things. It hides the field from view and disables the field so that it is not submitted. The conditional logic is seeing that the field should be shown and enabled and removing the disabled state in the JavaScript for conditional logic.
If you want this field to be visible even though it cannot be edited, then I don’t think there is any solution. The only think I can think of is to make it read only as well.
If you can get away with removing the field completely once it’s filled in you can return false from your filter and this will remove the field from display. Another option is that you can actually change the field type in your filter and change it to a message field, if you do this then there will be no field do edit.
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.