Skip Navigation

[Resolved] How to display custom field group on specific page in admin

This thread is resolved. Here is a description of the problem and solution.

Problem:
How to display custom field group on specific page in admin

Solution:
You can use WordPress function remove_meta_box() in order to remove the custom field group.

You can find the proposed solution, in this case, with the following reply:
=> https://toolset.com/forums/topic/post-field-group-not-saving-correctly/page/2/#post-1199207

Relevant Documentation:
https://codex.wordpress.org/Function_Reference/remove_meta_box

This support ticket is created 6 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 17 replies, has 5 voices.

Last updated by matthewL-7 5 years, 10 months ago.

Assisted by: Minesh.

Author
Posts
#1196455

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - can you share access details again so I can check whats going wrong on your install as our Devs confirmed that updating ALL Toolset plugins to it's latest official stable version resolve this issue.

But if you still have issue I would like to investigate on your install.

I have set the next reply to private which means only you and I have access to it.

#1199207

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - there is no way to control the custom field in admin section for specific page ID so I've added the following code to "Snippets":

function func_remove_tv_deals_meta_box() {
    global $post_type;
    global $post;
         
        if($post_type=='page' and $post->ID != 23044){
                remove_meta_box( 'wpcf-group-tv-deals', $post_type,'normal');
        }
    }
add_action('admin_head', 'func_remove_tv_deals_meta_box');

=> hidden link

I can see its working - can you please confirm.

#1199211

That is great thank you 🙂 works perfectly.