Digital experiences for all disciplines
New Landing › How can we help? › Themeforest Theme Support › Neighborhood › Remove Custom Post Types
New Landing › How can we help? › Themeforest Theme Support › Neighborhood › Remove Custom Post Types
- This topic has 20 replies, 6 voices, and was last updated 9 years by Mohammad – SUPPORT.
-
Posted in: Neighborhood
-
October 30, 2014 at 7:23 pm #124621
Hi
I’m not using the team, clients, portfolio, jobs or testimonials custom post types. Is there a way to remove them? They are cluttering up the website backend.
Thanks
October 31, 2014 at 5:15 am #124676Hi,
Please open to edit functions.php file of theme.
Find this code to remove :-
require_once(SF_INCLUDES_PATH . ‘/custom-post-types/portfolio-type.php’);
require_once(SF_INCLUDES_PATH . ‘/custom-post-types/team-type.php’);
require_once(SF_INCLUDES_PATH . ‘/custom-post-types/clients-type.php’);
require_once(SF_INCLUDES_PATH . ‘/custom-post-types/testimonials-type.php’);
require_once(SF_INCLUDES_PATH . ‘/custom-post-types/jobs-type.php’);
require_once(SF_INCLUDES_PATH . ‘/custom-post-types/faqs-type.php’);Thanks
MohammadNovember 3, 2014 at 4:28 pm #125207Thank you!
November 3, 2014 at 4:31 pm #125210No problem
– Kyle
January 27, 2015 at 8:31 pm #144915Hello Kyle, i want to do this too 🙂 but i have a child theme, how can i disable Dante custom post types from my child theme?
I work with a child theme so i can have Dante always with current.
Regards,
January 28, 2015 at 7:18 am #144975Hi,
You can remove custom post type through theme options settings.
Thanks
MohammadFebruary 15, 2015 at 7:56 pm #150279Hi!
I am using Neighbourhood Theme too but I do not see any options in the theme configuration to disable Custom Post Types…
I would like to do it within the Child theme just to keep myself safe from updates.
Looking forward to your reply!
February 16, 2015 at 2:26 am #150311Hi,
Please use this custom php code at functions.php of child theme.add_action( 'after_setup_theme','sf_custom_post_remove', 100 ); function sf_custom_post_remove() { remove_action( 'init', 'faqs_register'); remove_action( 'init', 'clients_register'); remove_action( 'init', 'jobs_register'); remove_action( 'init', 'portfolio_register'); remove_action( 'init', 'team_register'); remove_action( 'init', 'testimonials'); }
Thanks
MohammadFebruary 16, 2015 at 3:30 pm #150577Seems that portfolio is and testimonials are not gone yet…
Widgets get removed automatically too? Are they of any load to theme? I want to make it light because as you know being a complex theme its heavy on server.
Thanks!!
February 16, 2015 at 3:33 pm #150578Sorted!
remove_action( ‘init’, ‘faqs_register’);
remove_action( ‘init’, ‘clients_register’);
remove_action( ‘init’, ‘jobs_register’);
remove_action( ‘init’, ‘sf_portfolio_register’);
remove_action( ‘init’, ‘team_register’);
remove_action( ‘init’, ‘testimonials_register’);February 16, 2015 at 3:50 pm #150588Great. Thanks for sharing the solution.
-RuiFebruary 27, 2015 at 7:39 pm #153934Hello, i tried to remove a custom post type but this code did not work:
add_action( ‘after_setup_theme’,’sf_custom_post_remove’, 100 );
function sf_custom_post_remove() {
remove_action( ‘init’, ‘faqs_register’);
remove_action( ‘init’, ‘clients_register’);
remove_action( ‘init’, ‘jobs_register’);
remove_action( ‘init’, ‘portfolio_register’);
remove_action( ‘init’, ‘team_register’);
remove_action( ‘init’, ‘testimonials’);
}Also, Dante does not have theme options to remove any custom post type
February 28, 2015 at 1:52 pm #154013Hi,
Where did you insert this code?
Thanks
MohammadJune 12, 2015 at 4:00 pm #184076Hello Mohammad,
I pasted this code in the functions.php of both Dante and a child of Dante but the custom post types are still in the admin.
Please advise,
June 12, 2015 at 5:01 pm #184105 -
Posted in: Neighborhood
You must be logged in and have valid license to reply to this topic.