Support

Account

Home Forums Feature Requests Exclude checkbox for frontend form Reply To: Exclude checkbox for frontend form

  • I’d love to see an “admin/backend only” flag for fields.

    Right now I’m testing things with a simple approach:

    function prefix_hide_field($field) { return false; }
    add_filter(‘acf/load_field/name=/*somefield_1*/’, ‘prefix_hide_field’);
    add_filter(‘acf/load_field/name=/*somefield_2*/’, ‘prefix_hide_field’);
    /* … */
    add_filter(‘acf/load_field/name=/*somefield_n*/’, ‘prefix_hide_field’);

    But I fear the amount of add_filter()’s is going to eventually be a pain to maintain. Flagging fields would be a great help in terms of back-end UX design because in complex scenarios you will want to have logical groups of fields that pertain to a certain set of data and functions yet only allow access to a select set of those fields to members (from the front-end).

    Of course, it is possible to split options into different field groups and only include front-end-user field groups through the acf_form() options parameter but it makes it much harder and less intuitive from the standpoint of logically ordering things by areas of function.