Hide gavern- custom fields
WordPress theme dedicated to start-up websites with amazing CSS3 animated icons, price tables and parallax effect background.
- GK User
- Tue Jan 17, 2017 10:44 pm
I'm using wordpress 4.6.1 with the Simplicity theme.
When I publish a post I'm getting a bunch of custom fields displayed including:
gavern-post-desc
gavern-post-keywords
gavern-post-params-aside
gavern-post-params-image
gavern-post-params-templates
gavern-post-params-title
I've got custom fields disabled in the theme settings.
Is there a way to hide these gavern generated custom fields in the wp admin? Or stop them being generated? I'm using other custom fields and the display of these in the back end is getting in the way.
Ken
When I publish a post I'm getting a bunch of custom fields displayed including:
gavern-post-desc
gavern-post-keywords
gavern-post-params-aside
gavern-post-params-image
gavern-post-params-templates
gavern-post-params-title
I've got custom fields disabled in the theme settings.
Is there a way to hide these gavern generated custom fields in the wp admin? Or stop them being generated? I'm using other custom fields and the display of these in the back end is getting in the way.
Ken
-
- Expert Boarder
- Joshua M
- Wed Jan 18, 2017 9:36 am
Hello,
Hello, you can do it be removing the following lines from your Simplicity/gavern/base.php file:
but please notice, that some theme features like date, author, title, tags switcher (on/off) will not work anymore.
Hello, you can do it be removing the following lines from your Simplicity/gavern/base.php file:
- Code: Select all
add_action('add_meta_boxes', 'add_gavern_metaboxes' );
add_action('save_post', 'gavern_metaboxes_save' );
but please notice, that some theme features like date, author, title, tags switcher (on/off) will not work anymore.
-
- Moderator
- GK User
- Wed Jan 18, 2017 9:47 am
Perfect, thanks a lot!
1.Is it ok to just delete those custom fields from existing posts?
2. Is there a simple way to have my other custom fields automatically appear like that, rather than having to add them individually?
Thanks again, really appreciate your help.
Ken
1.Is it ok to just delete those custom fields from existing posts?
2. Is there a simple way to have my other custom fields automatically appear like that, rather than having to add them individually?
Thanks again, really appreciate your help.
Ken
-
- Expert Boarder
- Joshua M
- Wed Jan 18, 2017 10:06 am
1. Yes, but if you've used post switcher from right column - it won't work anymore.
2. Please check the solution introduced here: http://wordpress.stackexchange.com/ques ... ing-a-post
2. Please check the solution introduced here: http://wordpress.stackexchange.com/ques ... ing-a-post
-
- Moderator
- GK User
- Wed Jan 18, 2017 11:00 am
Great. Thanks again!
-
- Expert Boarder
- GK User
- Tue Jan 24, 2017 7:01 pm
Hi,
Sorry to resurrect this but...
I've belatedly discovered that I've used the sidebar options to disable the featured image (I need the featured image for NSP, but don't want it displayed in the post). I can see that the custom field labelled gavern-post-params-image is set to Y by default, so I'm guessing if I can set the default to N that will solve my problem. I've had a hunt around but can't find where this happens. Could you point me in the right direction please?
Thanks
Ken
Sorry to resurrect this but...
I've belatedly discovered that I've used the sidebar options to disable the featured image (I need the featured image for NSP, but don't want it displayed in the post). I can see that the custom field labelled gavern-post-params-image is set to Y by default, so I'm guessing if I can set the default to N that will solve my problem. I've had a hunt around but can't find where this happens. Could you point me in the right direction please?
Thanks
Ken
-
- Expert Boarder
- Joshua M
- Wed Jan 25, 2017 10:19 am
You can edit layouts/content.post.featured.php file and change this line:
into:
- Code: Select all
$params_image = isset($params['gavern-post-params-image']) ? esc_attr( $params['gavern-post-params-image'][0] ) : 'Y';
into:
- Code: Select all
$params_image = 'N';
-
- Moderator
- GK User
- Wed Jan 25, 2017 11:42 am
Great, thanks!
-
- Expert Boarder
8 posts
• Page 1 of 1