BP_REST_Account_Settings_Options_Endpoint::get_general_fields()
Get Fields for the General “Login Information”.
Description
- From: ‘members/single/settings/general’
Return
(array|mixed|void)
Source
File: bp-settings/classes/class-bp-rest-account-settings-options-endpoint.php
514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 | public function get_general_fields() { $fields = array (); if ( ! is_super_admin() ) { $fields [] = array ( 'name' => 'current_password' , 'label' => __( 'Current Password <span>(required to update email or change current password)</span>' , 'buddyboss' ), 'field' => 'password' , 'value' => '' , 'options' => array (), 'group_label' => '' , ); } $fields [] = array ( 'name' => 'account_email' , 'label' => __( 'Account Email' , 'buddyboss' ), 'field' => 'email' , 'value' => esc_attr( bp_core_get_user_email( bp_loggedin_user_id() ) ), 'options' => array (), 'group_label' => '' , ); $fields [] = array ( 'name' => 'pass1' , 'label' => __( 'Add Your New Password' , 'buddyboss' ), 'field' => 'password' , 'value' => '' , 'options' => array (), 'group_label' => '' , ); $fields [] = array ( 'name' => 'pass2' , 'label' => __( 'Repeat Your New Password' , 'buddyboss' ), 'field' => 'password' , 'value' => '' , 'options' => array (), 'group_label' => '' , ); $fields = apply_filters( 'bp_rest_account_settings_general' , $fields ); return $fields ; } |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.