Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
02/15/2012 08:33:09 PM (13 years ago)
Author:
boonebgorges
Message:

First pass at per-field visibility/privacy for XProfile:

  • Allows admins to set default levels for specific fields
  • Allows users to set visibility/privacy on a field-by-field basis
  • Modifies the profile templates to show markup for editing visibility status

See #3695

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-xprofile/bp-xprofile-screens.php

    r5729 r5789  
    114114                else
    115115                    do_action( 'xprofile_profile_field_data_updated', $field_id, $value );
     116               
     117                // Save the privacy level
     118                $privacy_level = !empty( $_POST['field_' . $field_id . '_privacy'] ) ? $_POST['field_' . $field_id . '_privacy'] : 'public';
     119                xprofile_set_field_privacy_level( $field_id, bp_displayed_user_id(), $privacy_level );
    116120            }
    117121
Note: See TracChangeset for help on using the changeset viewer.