I’m trying to delete some post meta fileds for specific user roles. “Author” to be exact. This is what I have so far. It deletes the field for the “Author” role, but also for admin. I just want to delete the field for “Author’s”.
NOTES: When you hook onto an action, the hooking should occur outside the function you’re using as a callback. For modifying metaboxes, use the do_meta_boxes hook, admin_menu is more appropriate for adding and removing admin menu items(hence the name).
Viewing 1 replies (of 1 total)
The topic ‘Remove metaboxes based on role’ is closed to new replies.