{"id":248795,"date":"2025-09-08T09:42:26","date_gmt":"2025-09-08T09:42:26","guid":{"rendered":"https:\/\/en-gb.wordpress.org\/plugins\/cpt-toggle-disable-custom-post-types\/"},"modified":"2025-09-08T09:54:49","modified_gmt":"2025-09-08T09:54:49","slug":"cpt-toggle-disable-custom-post-types","status":"publish","type":"plugin","link":"https:\/\/nb.wordpress.org\/plugins\/cpt-toggle-disable-custom-post-types\/","author":20728402,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_crdt_document":"","version":"1.5","stable_tag":"1.5","tested":"6.8.5","requires":"6.0","requires_php":"7.4","requires_plugins":null,"header_name":"CPT Toggle - Disable Custom Post Types","header_author":"Jay Kavanagh","header_description":"Toggle any Post Type (built-in or custom). Groups CPTs by source (Core, WooCommerce, Theme, specific plugin) with a tabbed UI.","assets_banners_color":"e7e7e8","last_updated":"2025-09-08 09:54:49","external_support_url":"","external_repository_url":"","donate_link":"https:\/\/designstack.co.uk\/","header_plugin_uri":"https:\/\/wordpress.org\/plugins\/cpt-toggle-disable-custom-post-types\/","header_author_uri":"https:\/\/designstack.co.uk","rating":0,"author_block_rating":0,"active_installs":20,"downloads":312,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.4":{"tag":"1.4","author":"designstack","date":"2025-09-08 09:41:51"},"1.5":{"tag":"1.5","author":"designstack","date":"2025-09-08 09:54:49"}},"upgrade_notice":{"1.2":"<p>Compliance fixes for WordPress.org review (paths, prefixing, text domain, escaping).<\/p>"},"ratings":[],"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":3357752,"resolution":"128x128","location":"assets","locale":""}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":3357752,"resolution":"1544x500","location":"assets","locale":""}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.4","1.5"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3357752,"resolution":"1","location":"assets","locale":""},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3357752,"resolution":"2","location":"assets","locale":""}},"screenshots":{"1":"Core tab showing CPTs and all other CPTs on the Wordpress installation.","2":"Example: theme tab showing disabled CPTs."},"jetpack_post_was_ever_published":false},"plugin_section":[],"plugin_tags":[83,2007,1794,3711,2133],"plugin_category":[],"plugin_contributors":[247548],"plugin_business_model":[],"class_list":["post-248795","plugin","type-plugin","status-publish","hentry","plugin_tags-admin","plugin_tags-cpt","plugin_tags-custom-post-type","plugin_tags-disable","plugin_tags-toggle","plugin_contributors-designstack","plugin_committers-designstack"],"banners":[],"icons":{"svg":false,"icon":"https:\/\/ps.w.org\/cpt-toggle-disable-custom-post-types\/assets\/icon-128x128.png?rev=3357752","icon_2x":false,"generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/cpt-toggle-disable-custom-post-types\/assets\/screenshot-1.png?rev=3357752","caption":"Core tab showing CPTs and all other CPTs on the Wordpress installation."},{"src":"https:\/\/ps.w.org\/cpt-toggle-disable-custom-post-types\/assets\/screenshot-2.png?rev=3357752","caption":"Example: theme tab showing disabled CPTs."}],"raw_content":"<!--section=description-->\n<p><strong>Custom Post Type Toggle<\/strong> gives you a clear overview of every registered post type on your site \u2014 whether they come from WordPress core, your theme, or installed plugins. Post types are grouped under tabs by their source, so it\u2019s easy to see what comes from where.<\/p>\n\n<p>If you don\u2019t need some post types (e.g. \u201cPortfolio\u201d from a theme you\u2019re not using, or \u201cTestimonials\u201d from a plugin), switch them off. Disabling hides the post type in admin and prevents it being used on the front end.<\/p>\n\n<p><strong>Why use it<\/strong>\n- Keep the admin menu uncluttered\n- Reduce confusion for editors and clients\n- Lighten the site by disabling unused post types<\/p>\n\n<p><strong>Features<\/strong>\n- Toggle any post type (core or custom) on\/off\n- Tabs that group post types by source (Core, theme, plugin)\n- Clean card-based interface with instant AJAX switching\n- Counters for enabled, disabled and total\n- Safe to use \u2014 re-enable at any time<\/p>\n\n<p><strong>How it works<\/strong>\nThe plugin inspects where <code>register_post_type()<\/code> is called from and labels the source as Core, active theme\/child theme, or a specific plugin name.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Upload the plugin folder to <code>\/wp-content\/plugins\/<\/code> or install via Plugins \u2192 Add New.<\/li>\n<li>Activate the plugin.<\/li>\n<li>Go to <strong>Settings \u2192 CPT Toggle<\/strong>.<\/li>\n<li>Use the tabs to view sources; flip the switches to enable\/disable post types.<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id='does%20disabling%20delete%20any%20content%3F'><h3>Does disabling delete any content?<\/h3><\/dt>\n<dd><p>No. Content remains in the database. Re-enable the post type to access it again.<\/p><\/dd>\n<dt id='will%20permalinks%20need%20refreshing%3F'><h3>Will permalinks need refreshing?<\/h3><\/dt>\n<dd><p>Usually not. If you\u2019ve changed a lot, visit <strong>Settings \u2192 Permalinks<\/strong> and click <strong>Save<\/strong> to flush rules.<\/p><\/dd>\n<dt id='some%20post%20types%20show%20under%20%E2%80%9Cunknown%E2%80%9D.%20why%3F'><h3>Some post types show under \u201cUnknown\u201d. Why?<\/h3><\/dt>\n<dd><p>Occasionally a source can\u2019t be inferred from the stack. Tell us the CPT slug and we\u2019ll refine detection.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.5<\/h4>\n\n<ul>\n<li>Fixed contributors<\/li>\n<\/ul>\n\n<h4>1.4<\/h4>\n\n<ul>\n<li>Prepared for public release<\/li>\n<li>Bumped version to 1.4.<\/li>\n<\/ul>\n\n<h4>1.3<\/h4>\n\n<ul>\n<li>Fixed .org review error: Plugin URI and Author URI are now different.<\/li>\n<li>Bumped version to 1.3.<\/li>\n<\/ul>\n\n<h4>1.2<\/h4>\n\n<ul>\n<li>Paths: replaced internal constants with plugin-agnostic detection (active\/network\/MU plugins) for source mapping.<\/li>\n<li>Prefixing: unique <code>cptt_dcp<\/code> prefix across class, options, AJAX and handles.<\/li>\n<li>i18n: text domain now matches slug (<code>cpt-toggle-disable-custom-post-types<\/code>).<\/li>\n<li>Security: moved dynamic data to JSON-injected object for inline JS (proper escaping).<\/li>\n<li>Uninstall: cleans both new and legacy option names.<\/li>\n<\/ul>\n\n<h4>1.1<\/h4>\n\n<ul>\n<li>Added translators comment before footer string with placeholder.<\/li>\n<li>Renamed plugin to \u201cCPT Toggle \u2013 Disable Custom Post Types\u201d.<\/li>\n<li>Bumped stable tag to 1.1.<\/li>\n<\/ul>\n\n<h4>1.0<\/h4>\n\n<ul>\n<li>Added translators comments for placeholder strings.<\/li>\n<li>Removed load_plugin_textdomain() (WP.org auto-loads language packs).<\/li>\n<li>Sanitised\/unslashed AJAX inputs; validated indexes; clearer error output.<\/li>\n<li>Readme: updated \u201cTested up to\u201d, trimmed tags to 5, short description to \u2264150 chars.<\/li>\n<\/ul>\n\n<h4>0.9<\/h4>\n\n<ul>\n<li>Prepared WordPress.org assets, readme, license, uninstall.<\/li>\n<li>Minor copy tweaks.<\/li>\n<\/ul>\n\n<h4>0.8<\/h4>\n\n<ul>\n<li>Tabs now scroll horizontally when there are many sources.<\/li>\n<li>Smooth scroll to the active tab.<\/li>\n<\/ul>\n\n<h4>0.7<\/h4>\n\n<ul>\n<li>More reliable source detection (skip this plugin in backtrace).<\/li>\n<li>Capture during <code>register_post_type_args<\/code>.<\/li>\n<\/ul>\n\n<h4>0.6<\/h4>\n\n<ul>\n<li>Introduced tabbed UI, grouped by source (Core, plugins, theme).<\/li>\n<li>Card layout, AJAX toggles, counts.<\/li>\n<\/ul>","raw_excerpt":"Enable or disable any post type. Tabs group post types by source (Core, theme, plugin) for a tidy WordPress admin.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/248795","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=248795"}],"author":[{"embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/designstack"}],"wp:attachment":[{"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=248795"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=248795"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=248795"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=248795"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=248795"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/nb.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=248795"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}