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.
- profile properties of the user
- user group membership
- values of fields in list items