Dear Sir/Madam,
Refer to the screenshot, is it possible to remove the Add button? I don't user can add post from here?
Best regards,
Kelvin.

Minesh
Supporter
Les langues:
Anglais (English )
Fuseau horaire:
Asia/Kolkata (GMT+05:30)
Hello. Thank you for contacting the Toolset support.
There is no native way to remove "Add New" button but we can workaround it either by adding custom CSS or JS code.
I would like to know for what users you would like to remove the Add new button. With what user role you want to hide/remove the add new button?
Dear Minesh,
I have custom Toolset user role say 'staff', only the administrator or staff can "Add New".
Best regards,
Kelvin.
You can add the following custom code to your theme's functions.php file or "Custom Code" section offered by Toolset:
=> https://toolset.com/documentation/programmer-reference/adding-custom-code/using-toolset-to-add-custom-code/
function func_hild_add_new_post_relationship_box_button() {
$user = wp_get_current_user();
if ( !in_array( 'administrator', (array) $user->roles) or !in_array( 'staff', (array) $user->roles) ) {
echo '<style> .types-related-content .types-related-content-actions input.button:nth-of-type(1){
display: none !important;
}
</style>';
}
}
add_action( 'admin_head', 'func_hild_add_new_post_relationship_box_button' );