Skip to main content
replaced http://wordpress.stackexchange.com/ with https://wordpress.stackexchange.com/
Source Link

I don't develop themes, but when building a site I achieve this kind of setup you describe using the plugin Advanced Custom Fields.

With it, I can hook custom meta boxes (text, image, checkboxes, dropdowns, etc) into posts, pages and CPTs, and fine tune their appearance according to page-template, categories and other conditionals. It can also hide the default WordPress boxes and meta boxes.

Based on this custom fields, I'm able to render the front pages and posts with great detail.

That said, there's this class (Custom Metaboxes and Fields for WordPress), for theme inclusion, that may be able to give you the same functionality. I haven't used it, because ACF gives me that and it's theme independent.

You can also study how ACF works. In this answerthis answer, I'm using his code as base to enable/disable the visibility of the Featured Image meta box according to the selected page template.

I don't develop themes, but when building a site I achieve this kind of setup you describe using the plugin Advanced Custom Fields.

With it, I can hook custom meta boxes (text, image, checkboxes, dropdowns, etc) into posts, pages and CPTs, and fine tune their appearance according to page-template, categories and other conditionals. It can also hide the default WordPress boxes and meta boxes.

Based on this custom fields, I'm able to render the front pages and posts with great detail.

That said, there's this class (Custom Metaboxes and Fields for WordPress), for theme inclusion, that may be able to give you the same functionality. I haven't used it, because ACF gives me that and it's theme independent.

You can also study how ACF works. In this answer, I'm using his code as base to enable/disable the visibility of the Featured Image meta box according to the selected page template.

I don't develop themes, but when building a site I achieve this kind of setup you describe using the plugin Advanced Custom Fields.

With it, I can hook custom meta boxes (text, image, checkboxes, dropdowns, etc) into posts, pages and CPTs, and fine tune their appearance according to page-template, categories and other conditionals. It can also hide the default WordPress boxes and meta boxes.

Based on this custom fields, I'm able to render the front pages and posts with great detail.

That said, there's this class (Custom Metaboxes and Fields for WordPress), for theme inclusion, that may be able to give you the same functionality. I haven't used it, because ACF gives me that and it's theme independent.

You can also study how ACF works. In this answer, I'm using his code as base to enable/disable the visibility of the Featured Image meta box according to the selected page template.

Source Link
brasofilo
  • 22.1k
  • 8
  • 69
  • 264

I don't develop themes, but when building a site I achieve this kind of setup you describe using the plugin Advanced Custom Fields.

With it, I can hook custom meta boxes (text, image, checkboxes, dropdowns, etc) into posts, pages and CPTs, and fine tune their appearance according to page-template, categories and other conditionals. It can also hide the default WordPress boxes and meta boxes.

Based on this custom fields, I'm able to render the front pages and posts with great detail.

That said, there's this class (Custom Metaboxes and Fields for WordPress), for theme inclusion, that may be able to give you the same functionality. I haven't used it, because ACF gives me that and it's theme independent.

You can also study how ACF works. In this answer, I'm using his code as base to enable/disable the visibility of the Featured Image meta box according to the selected page template.