Support

Account

Home Forums ACF PRO hide fields from non-admin users

Helping

hide fields from non-admin users

  • Is this possible?

    Specifically I want to hide a TAB and the fields in that tab from non-Admin users on the front end.

    Any help appreciated! ๐Ÿ™‚

  • There isn’t any way to hide a tab and all of it’s sub fields based on the user role, removing the tab field would simply put the fields into the previous tab.

    This would need to be done on the tab field and all of the fields in that tab.

    You would need to create an acf/prepare_field filter https://www.advancedcustomfields.com/resources/acfprepare_field/ and attach it to every field you want to remove. In you filter you would check the current user’s role. If the user is not supposed to see this field the you return false from your filter and this will remove the field from field group for that user.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.