I have a WordPress site using custom post types, and I have also got the All In One SEO pack installed.
I wondered if anyone knows a hack or a modification I can make to the code which will allow me to stop the pictured area from showing up on certain custom post types?
Any help much appreciated.
If you’re satisfied with disabling the SEO-Pack on all CPTs, go with brasoflo’s answer.
Should you want to keep the metabox for some CPTs and disable it only for a select few:
Where
'movie'
is, going with brasoflo’s answer, the name of the CPT. Repeat the call toremove_meta_box();
for each post type you want to target. If it’s a fairly high number, you could wrap it in a loop:It might sound a bit confusing, that I suggest hooking the function with the
'add_meta_boxes'
action when you want to remove one, but this action runs after all meta boxes have been added, hence that’s when existing ones can be removed. If you ran the function too early, the box would get added afterwards.Looks like it’s just a matter of configuring the plugin…
/wp-admin/options-general.php?page=all-in-one-seo-pack/aioseop.class.php