Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
10/01/2015 04:18:13 AM (10 years ago)
Author:
tw2113
Message:

First pass of documentation cleanup for the XProfile Component.

See #6406.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-xprofile/bp-xprofile-actions.php

    r10140 r10163  
    2020 * The function will delete the active avatar for a user.
    2121 *
    22  * @package BuddyPress Xprofile
    2322 * @uses bp_core_delete_avatar() Deletes the active avatar for the logged in user.
    2423 * @uses add_action() Runs a specific function for an action when it fires.
     
    3029    }
    3130
    32     // Check the nonce
     31    // Check the nonce.
    3332    check_admin_referer( 'bp_delete_avatar_link' );
    3433
     
    4847
    4948/**
    50  * Handles the saving of xprofile field visibilities
     49 * Handles the saving of xprofile field visibilities.
    5150 *
    5251 * @since 1.9.0
     
    5453function bp_xprofile_action_settings() {
    5554
    56     // Bail if not a POST action
     55    // Bail if not a POST action.
    5756    if ( 'POST' !== strtoupper( $_SERVER['REQUEST_METHOD'] ) ) {
    5857        return;
    5958    }
    6059
    61     // Bail if no submit action
     60    // Bail if no submit action.
    6261    if ( ! isset( $_POST['xprofile-settings-submit'] ) ) {
    6362        return;
    6463    }
    6564
    66     // Bail if not in settings
     65    // Bail if not in settings.
    6766    if ( ! bp_is_user_settings_profile() ) {
    6867        return;
     
    7574    }
    7675
    77     // Nonce check
     76    // Nonce check.
    7877    check_admin_referer( 'bp_xprofile_settings' );
    7978
     
    8786    /** Save ******************************************************************/
    8887
    89     // Only save if there are field ID's being posted
     88    // Only save if there are field ID's being posted.
    9089    if ( ! empty( $_POST['field_ids'] ) ) {
    9190
    92         // Get the POST'ed field ID's
     91        // Get the POST'ed field ID's.
    9392        $posted_field_ids = explode( ',', $_POST['field_ids'] );
    9493
     
    104103        }
    105104
    106         // Save the visibility settings
     105        // Save the visibility settings.
    107106        foreach ( $posted_field_ids as $field_id ) {
    108107
     
    126125    do_action( 'bp_xprofile_settings_after_save' );
    127126
    128     // Redirect to the root domain
     127    // Redirect to the root domain.
    129128    bp_core_redirect( bp_displayed_user_domain() . bp_get_settings_slug() . '/profile' );
    130129}
Note: See TracChangeset for help on using the changeset viewer.