Skip to content

Instantly share code, notes, and snippets.

@billerickson
Created October 9, 2011 14:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save billerickson/1273769 to your computer and use it in GitHub Desktop.
Save billerickson/1273769 to your computer and use it in GitHub Desktop.
Patch to make genesis seo and layout options post-type-specific
Index: lib/admin/inpost-metaboxes.php
===================================================================
--- lib/admin/inpost-metaboxes.php (revision 227)
+++ lib/admin/inpost-metaboxes.php (working copy)
@@ -22,7 +22,7 @@
function genesis_add_inpost_seo_box() {
foreach ( (array)get_post_types( array( 'public' => true ) ) as $type ) {
- if ( post_type_supports( $type, 'genesis-seo' ) || $type == 'post' || $type = 'page' ) {
+ if ( post_type_supports( $type, 'genesis-seo' ) ) {
add_meta_box('genesis_inpost_seo_box', __('Genesis SEO Settings', 'genesis'), 'genesis_inpost_seo_box', $type, 'normal', 'high');
}
}
@@ -150,7 +150,7 @@
return;
foreach ( (array)get_post_types( array( 'public' => true ) ) as $type ) {
- if ( post_type_supports( $type, 'genesis-layouts' ) || $type == 'post' || $type = 'page' ) {
+ if ( post_type_supports( $type, 'genesis-layouts' ) ) {
add_meta_box('genesis_inpost_layout_box', __('Genesis Layout Settings', 'genesis'), 'genesis_inpost_layout_box', $type, 'normal', 'high');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment