Is it possible to hide some publishing fields on page layouts based on page content type field values? For example, if some field named Show Main Image is not set to true, I don't want to show Main Image field on the page.


No using the OOTB field controls.

Hiding the main image is usually done by having a seperate pagelayout without that field and what might be needed around it.

| improve this answer | |

I usually solve requirements like this using javascript/jQuery on the page layout. It should be pretty straight forward to add an onclick/toggle function when the user sets a field to true. Using javascript CSOM, you could also do other things to show/hide fields depending on conditions. I've previously toggled fields based on

  • profile properties of the user
  • user group membership
  • values of fields in list items
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.