Skip to:
Content

BuddyPress.org

Changeset 10740


Ignore:
Timestamp:
05/07/2016 07:38:27 PM (4 years ago)
Author:
tw2113
Message:

Continued XProfile docs cleanup.

See #6406.

Location:
trunk/src/bp-xprofile
Files:
15 edited

Legend:

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

    r10434 r10740  
    2020 *
    2121 * The function will delete the active avatar for a user.
     22 *
     23 * @since 1.0.0
    2224 *
    2325 * @uses bp_core_delete_avatar() Deletes the active avatar for the logged in user.
  • trunk/src/bp-xprofile/bp-xprofile-admin.php

    r10657 r10740  
    1818 * Creates the administration interface menus and checks to see if the DB
    1919 * tables are set up.
     20 *
     21 * @since 1.0.0
    2022 *
    2123 * @uses bp_current_user_can() returns true if the current user is a site admin, false if not.
     
    3941 * profile groups and fields.
    4042 *
     43 * @since 1.0.0
     44 *
    4145 * @param string $message Message to display.
    4246 * @param string $type    Type of action to be displayed.
     
    7175
    7276/**
    73  * Output the main XProfile management screen
     77 * Output the main XProfile management screen.
    7478 *
    7579 * @since 2.3.0
     
    243247 * Handles the adding or editing of groups.
    244248 *
     249 * @since 1.0.0
     250 *
    245251 * @param int|null $group_id Group ID to manage.
    246252 */
     
    305311/**
    306312 * Handles the deletion of profile data groups.
     313 *
     314 * @since 1.0.0
    307315 *
    308316 * @param int $group_id ID of the group to delete.
     
    337345 * Handles the adding or editing of profile field data for a user.
    338346 *
     347 * @since 1.0.0
     348 *
    339349 * @param int      $group_id ID of the group.
    340350 * @param int|null $field_id ID of the field being managed.
     
    453463 *
    454464 * @since 1.0.0
     465 *
    455466 * @global string $message The feedback message to show.
    456467 * @global $type The type of feedback message to show.
  • trunk/src/bp-xprofile/bp-xprofile-filters.php

    r10557 r10740  
    8383 * @since 2.3.0
    8484 *
    85  * @param  mixed $field_options Options to sanitize.
    86  *
     85 * @param mixed $field_options Options to sanitize.
    8786 * @return mixed
    8887 */
     
    10099 * @since 2.3.0
    101100 *
    102  * @param  mixed $field_default Field defaults to sanitize.
    103  *
     101 * @param mixed $field_default Field defaults to sanitize.
    104102 * @return mixed
    105103 */
     
    115113 * Run profile field values through kses with filterable allowed tags.
    116114 *
     115 * @since 1.5.0
     116 *
    117117 * @param string      $content  Content to filter.
    118118 * @param object|null $data_obj The BP_XProfile_ProfileData object.
    119  *
    120119 * @return string $content
    121120 */
     
    155154 * Safely runs profile field data through kses and force_balance_tags.
    156155 *
     156 * @since 1.2.6
     157 *
    157158 * @param string      $field_value Field value being santized.
    158159 * @param int         $field_id    Field ID being sanitized.
    159160 * @param bool        $reserialize Whether to reserialize arrays before returning. Defaults to true.
    160161 * @param object|null $data_obj    The BP_XProfile_ProfileData object.
    161  *
    162162 * @return string
    163163 */
     
    217217 * @param string $field_value XProfile field_value to be filtered.
    218218 * @param string $field_type  XProfile field_type to be filtered.
    219  *
    220219 * @return string $field_value Filtered XProfile field_value. False on failure.
    221220 */
     
    243242 * @param string     $field_type  Field type.
    244243 * @param string|int $field_id    Optional. ID of the field.
    245  *
    246244 * @return mixed
    247245 */
     
    394392 * and swaps out user data with BP xprofile data, where available.
    395393 *
     394 * @since 1.2.0
     395 *
    396396 * @param array $comments Comments to filter in.
    397397 * @param int   $post_id  Post ID the comments are for.
    398  *
    399398 * @return array $comments
    400399 */
  • trunk/src/bp-xprofile/bp-xprofile-functions.php

    r10434 r10740  
    2525 * @since 2.1.0
    2626 *
    27  * @param array $args See {@link BP_XProfile_Group::get()} for description of
    28  *                    arguments.
     27 * @param array $args See {@link BP_XProfile_Group::get()} for description of arguments.
    2928 * @return array $groups
    3029 */
     
    4948 * @since 1.0.0
    5049 *
    51  * @param array|string $args Array of arguments for field group insertion.
     50 * @param array|string $args {
     51 *    Array of arguments for field group insertion.
     52 *
     53 *    @type int|bool    $field_group_id ID of the field group to insert into.
     54 *    @type string|bool $name           Name of the group.
     55 *    @type string      $description    Field group description.
     56 *    @type bool        $can_delete     Whether or not the field group can be deleted.
     57 * }
    5258 * @return boolean
    5359 */
     
    193199/**
    194200 * Insert or update an xprofile field.
     201 *
     202 * @since 1.1.0
    195203 *
    196204 * @param array|string $args {
     
    274282 * Get a profile field object.
    275283 *
     284 * @since 1.1.0
     285 *
    276286 * @param int|object $field ID of the field or object representing field data.
    277287 * @return BP_XProfile_Field|null Field object if found, otherwise null.
     
    297307 * Delete a profile field object.
    298308 *
     309 * @since 1.1.0
     310 *
    299311 * @param int|object $field_id ID of the field or object representing field data.
    300312 * @return bool Whether or not the field was deleted.
     
    313325 * When the field value is serialized, this function unserializes and filters
    314326 * each item in the array.
     327 *
     328 * @since 1.0.0
    315329 *
    316330 * @uses BP_XProfile_ProfileData::get_value_byid() Fetches the value based on the params passed.
     
    374388 * A simple function to set profile data for a specific field for a specific user.
    375389 *
     390 * @since 1.0.0
     391 *
    376392 * @uses xprofile_get_field_id_from_name() Gets the ID from the field based on the name.
    377393 *
     
    455471 * Set the visibility level for this field.
    456472 *
     473 * @since 1.6.0
     474 *
    457475 * @param int    $field_id         The ID of the xprofile field.
    458476 * @param int    $user_id          The ID of the user to whom the data belongs.
     
    519537/**
    520538 * Delete XProfile field data.
     539 *
     540 * @since 1.1.0
    521541 *
    522542 * @param string $field   Field to delete.
     
    548568 * Check if field is a required field.
    549569 *
     570 * @since 1.1.0
     571 *
    550572 * @param int $field_id ID of the field to check for.
    551573 * @return bool Whether or not field is required.
     
    565587 * Returns the ID for the field based on the field name.
    566588 *
    567  * @package BuddyPress Core
     589 * @since 1.0.0
     590 *
    568591 * @param string $field_name The name of the field to get the ID for.
    569592 * @return int $field_id on success, false on failure.
     
    575598/**
    576599 * Fetches a random piece of profile data for the user.
     600 *
     601 * @since 1.0.0
    577602 *
    578603 * @global BuddyPress $bp           The one true BuddyPress instance.
     
    612637 * Formats a profile field according to its type. [ TODO: Should really be moved to filters ]
    613638 *
     639 * @since 1.0.0
     640 *
    614641 * @param string $field_type  The type of field: datebox, selectbox, textbox etc.
    615642 * @param string $field_value The actual value.
     
    634661/**
    635662 * Update the field position for a provided field.
     663 *
     664 * @since 1.1.0
    636665 *
    637666 * @param int $field_id       ID of the field to update.
     
    769798 * Syncs Xprofile data to the standard built in WordPress profile data.
    770799 *
     800 * @since 1.0.0
     801 *
    771802 * @param int $user_id ID of the user to sync.
    772803 * @return bool
     
    836867 * usermeta table that this component uses.
    837868 *
     869 * @since 1.0.0
     870 *
    838871 * @param int $user_id The ID of the deleted user.
    839872 */
     
    849882/**
    850883 * Delete a piece of xprofile metadata.
     884 *
     885 * @since 1.5.0
    851886 *
    852887 * @param int         $object_id   ID of the object the metadata belongs to.
     
    902937 * underlying get_metadata() function. This is for backward compatibility.
    903938 *
     939 * @since 1.5.0
     940 *
    904941 * @param int    $object_id   ID of the object the metadata belongs to.
    905942 * @param string $object_type Type of object. 'group', 'field', or 'data'.
     
    928965/**
    929966 * Update a piece of xprofile metadata.
     967 *
     968 * @since 1.5.0
    930969 *
    931970 * @param int    $object_id   ID of the object the metadata belongs to.
     
    9781017 * Updates the fieldgroup metadata.
    9791018 *
     1019 * @since 1.5.0
     1020 *
    9801021 * @param int    $field_group_id Group ID for the group field belongs to.
    9811022 * @param string $meta_key       Meta key to update.
     
    9901031 * Updates the field metadata.
    9911032 *
     1033 * @since 1.5.0
     1034 *
    9921035 * @param int    $field_id   Field ID to update.
    9931036 * @param string $meta_key   Meta key to update.
     
    10021045 * Updates the fielddata metadata.
    10031046 *
     1047 * @since 1.5.0
     1048 *
    10041049 * @param int    $field_data_id Field ID to update.
    10051050 * @param string $meta_key      Meta key to update.
     
    10881133 * Get visibility levels out of the $bp global.
    10891134 *
     1135 * @since 1.6.0
     1136 *
    10901137 * @return array
    10911138 */
     
    11111158 *
    11121159 * @since 1.6.0
     1160 *
    11131161 * @see BP_XProfile_Group::get()
    11141162 * @uses apply_filters() Filter bp_xprofile_get_hidden_fields_for_user to modify visibility levels,
     
    11581206 *
    11591207 * @since 1.8.2
     1208 *
    11601209 * @see bp_xprofile_get_hidden_fields_for_user()
    11611210 *
     
    12041253 *
    12051254 * @since 1.6.0
     1255 *
    12061256 * @see bp_xprofile_get_hidden_fields_for_user()
    12071257 *
  • trunk/src/bp-xprofile/bp-xprofile-loader.php

    r10652 r10740  
    2020/**
    2121 * Bootstrap the XProfile component.
     22 *
     23 * @since 1.6.0
    2224 */
    2325function bp_setup_xprofile() {
  • trunk/src/bp-xprofile/bp-xprofile-screens.php

    r10434 r10740  
    1818 * Handles the display of the profile page by loading the correct template file.
    1919 *
     20 * @since 1.0.0
     21 *
    2022 * @uses bp_core_load_template() Looks for and loads a template file within the current member theme (folder/filename).
    2123 */
     
    4547 * Handles the display of the profile edit page by loading the correct template file.
    4648 * Also checks to make sure this can only be accessed for the logged in users profile.
     49 *
     50 * @since 1.0.0
    4751 *
    4852 * @uses bp_is_my_profile() Checks to make sure the current user being viewed equals the logged in user.
     
    203207/**
    204208 * Handles the uploading and cropping of a user avatar. Displays the change avatar page.
     209 *
     210 * @since 1.0.0
    205211 *
    206212 * @uses bp_is_my_profile() Checks to make sure the current user being viewed equals the logged in user.
     
    297303 * Displays the change cover image page.
    298304 *
    299  * @package BuddyPress XProfile
    300  *
    301305 * @since 2.4.0
    302306 */
  • trunk/src/bp-xprofile/bp-xprofile-template.php

    r10712 r10740  
    8484 * Start off the profile groups.
    8585 *
     86 * @since 1.0.0
     87 *
    8688 * @return mixed
    8789 */
     
    9496 * Set up the profile groups.
    9597 *
     98 * @since 1.0.0
     99 *
    96100 * @return mixed
    97101 */
     
    104108 * Whether or not the group has fields to display.
    105109 *
     110 * @since 1.0.0
     111 *
    106112 * @return mixed
    107113 */
     
    116122 * @since 1.0.0
    117123 *
    118  * @param array|string|false $class Extra classes to append to class attribute.
    119  *                                  Pass mutiple class names as an array or
    120  *                                  space-delimited string.
    121  * @return string
     124 * @param mixed $class Extra classes to append to class attribute.
     125 *                     Pass mutiple class names as an array or
     126 *                     space-delimited string.
    122127 */
    123128function bp_field_css_class( $class = false ) {
     
    127132    /**
    128133     * Return the class attribute for a field.
     134     *
     135     * @since 1.1.0
    129136     *
    130137     * @param string|bool $class Extra classes to append to class attribute.
     
    187194 * Whether or not the XProfile field has data to display.
    188195 *
     196 * @since 1.0.0
     197 *
     198 * @global object $profile_template
     199 *
    189200 * @return mixed
    190201 */
     
    197208 * Whether or not the XProfile field has public data to display.
    198209 *
     210 * @since 1.0.0
     211 *
     212 * @global object $profile_template
     213 *
    199214 * @return bool
    200215 */
     
    211226/**
    212227 * Output the XProfile group ID.
     228 *
     229 * @since 1.0.0
    213230 */
    214231function bp_the_profile_group_id() {
     
    219236     * Return the XProfile group ID.
    220237     *
     238     * @since 1.1.0
     239     *
    221240     * @return mixed|void
    222241     */
     
    236255/**
    237256 * Output the XProfile group name.
     257 *
     258 * @since 1.0.0
    238259 */
    239260function bp_the_profile_group_name() {
     
    244265     * Return the XProfile group name.
    245266     *
     267     * @since 1.0.0
     268     *
    246269     * @return mixed|void
    247270     */
     
    261284/**
    262285 * Output the XProfile group slug.
     286 *
     287 * @since 1.1.0
    263288 */
    264289function bp_the_profile_group_slug() {
     
    269294     * Return the XProfile group slug.
    270295     *
     296     * @since 1.1.0
     297     *
    271298     * @return mixed|void
    272299     */
     
    286313/**
    287314 * Output the XProfile group description.
     315 *
     316 * @since 1.0.0
    288317 */
    289318function bp_the_profile_group_description() {
     
    294323     * Return the XProfile group description.
    295324     *
     325     * @since 1.0.0
     326     *
    296327     * @return mixed|void
    297328     */
     
    311342/**
    312343 * Output the XProfile group edit form action.
     344 *
     345 * @since 1.1.0
    313346 */
    314347function bp_the_profile_group_edit_form_action() {
     
    319352     * Return the XProfile group edit form action.
    320353     *
     354     * @since 1.1.0
     355     *
    321356     * @return mixed|void
    322357     */
     
    340375/**
    341376 * Output the XProfile group field IDs.
     377 *
     378 * @since 1.1.0
    342379 */
    343380function bp_the_profile_group_field_ids() {
     
    347384    /**
    348385     * Return the XProfile group field IDs.
     386     *
     387     * @since 1.1.0
    349388     *
    350389     * @return string
     
    404443 * Return the XProfile fields.
    405444 *
     445 * @since 1.0.0
     446 *
    406447 * @return mixed
    407448 */
     
    414455 * Sets up the XProfile field.
    415456 *
     457 * @since 1.0.0
     458 *
    416459 * @return mixed
    417460 */
     
    423466/**
    424467 * Output the XProfile field ID.
     468 *
     469 * @since 1.1.0
    425470 */
    426471function bp_the_profile_field_id() {
     
    430475    /**
    431476     * Return the XProfile field ID.
     477     *
     478     * @since 1.1.0
     479     *
    432480     * @return mixed|void
    433481     */
     
    447495/**
    448496 * Outputs the XProfile field name.
     497 *
     498 * @since 1.0.0
    449499 */
    450500function bp_the_profile_field_name() {
     
    455505     * Returns the XProfile field name.
    456506     *
     507     * @since 1.0.0
     508     *
    457509     * @return mixed|void
    458510     */
     
    472524/**
    473525 * Outputs the XProfile field value.
     526 *
     527 * @since 1.0.0
    474528 */
    475529function bp_the_profile_field_value() {
     
    479533    /**
    480534     * Returns the XProfile field value.
     535     *
     536     * @since 1.0.0
    481537     *
    482538     * @return mixed|void
     
    501557/**
    502558 * Outputs the XProfile field edit value.
     559 *
     560 * @since 1.1.0
    503561 */
    504562function bp_the_profile_field_edit_value() {
     
    508566    /**
    509567     * Returns the XProfile field edit value.
     568     *
     569     * @since 1.1.0
    510570     *
    511571     * @return mixed|void
     
    550610/**
    551611 * Outputs the XProfile field type.
     612 *
     613 * @since 1.1.0
    552614 */
    553615function bp_the_profile_field_type() {
     
    558620     * Returns the XProfile field type.
    559621     *
     622     * @since 1.1.0
     623     *
    560624     * @return mixed|void
    561625     */
     
    575639/**
    576640 * Outputs the XProfile field description.
     641 *
     642 * @since 1.1.0
    577643 */
    578644function bp_the_profile_field_description() {
     
    583649     * Returns the XProfile field description.
    584650     *
     651     * @since 1.1.0
     652     *
    585653     * @return mixed|void
    586654     */
     
    600668/**
    601669 * Outputs the XProfile field input name.
     670 *
     671 * @since 1.1.0
    602672 */
    603673function bp_the_profile_field_input_name() {
     
    607677    /**
    608678     * Retursn the XProfile field input name.
     679     *
     680     * @since 1.1.0
    609681     *
    610682     * @return mixed|void
     
    706778/**
    707779 * Render whether or not a profile field is required.
     780 *
     781 * @since 1.1.0
    708782 */
    709783function bp_the_profile_field_is_required() {
     
    713787    /**
    714788     * Return whether or not a profile field is required.
     789     *
     790     * @since 1.1.0
     791     *
    715792     * @return mixed|void
    716793     */
     
    736813/**
    737814 * Output the visibility level of this field.
     815 *
     816 * @since 1.6.0
    738817 */
    739818function bp_the_profile_field_visibility_level() {
     
    743822    /**
    744823     * Return the visibility level of this field.
     824     *
     825     * @since 1.6.0
    745826     *
    746827     * @return mixed|void
     
    770851/**
    771852 * Echo the visibility level label of this field.
     853 *
     854 * @since 1.6.0
    772855 */
    773856function bp_the_profile_field_visibility_level_label() {
     
    777860    /**
    778861     * Return the visibility level label of this field.
     862     *
     863     * @since 1.6.0
    779864     *
    780865     * @return mixed|void
     
    807892 * Return unserialized profile field data.
    808893 *
     894 * @since 1.0.0
     895 *
    809896 * @param string $value Content to maybe unserialize.
    810897 * @return mixed|string
     
    823910 * Output XProfile field data.
    824911 *
    825  * @param string|array $args Array of arguments for field data.
     912 * @since 1.2.0
     913 *
     914 * @param string|array $args Array of arguments for field data. See {@link bp_get_profile_field_data}
    826915 */
    827916function bp_profile_field_data( $args = '' ) {
     
    832921     * Return XProfile field data.
    833922     *
    834      * @param string|array $args Array of arguments for field data.
    835      * @return mixed|void
     923     * @since 1.2.0
     924     *
     925     * @param string|array $args {
     926     *    Array of arguments for field data.
     927     *
     928     *    @type string|int|bool $field   Field identifier.
     929     *    @type int             $user_id ID of the user to get field data for.
     930     * }
     931     * @return mixed|void
    836932     */
    837933    function bp_get_profile_field_data( $args = '' ) {
     
    9711067 * Output the XProfile group name.
    9721068 *
     1069 * @since 1.0.0
     1070 *
    9731071 * @param bool $deprecated Deprecated boolean parameter.
    9741072 * @return mixed|void
     
    9851083     * Return the XProfile group name.
    9861084     *
     1085     * @since 1.0.0
     1086     *
    9871087     * @return mixed|void
    9881088     */
     
    10101110/**
    10111111 * Render a formatted string displaying when a profile was last updated.
     1112 *
     1113 * @since 1.0.0
    10121114 */
    10131115function bp_profile_last_updated() {
     
    10241126    /**
    10251127     * Return a formatted string displaying when a profile was last updated.
     1128     *
     1129     * @since 1.0.0
    10261130     *
    10271131     * @return bool|mixed|void
     
    10481152/**
    10491153 * Display the current profile group ID.
     1154 *
     1155 * @since 1.1.0
    10501156 */
    10511157function bp_current_profile_group_id() {
     
    10801186/**
    10811187 * Render an avatar delete link.
     1188 *
     1189 * @since 1.1.0
    10821190 */
    10831191function bp_avatar_delete_link() {
     
    10891197     *
    10901198     * @since 1.1.0
     1199     *
    10911200     * @return mixed|void
    10921201     */
     
    11051214/**
    11061215 * Render an edit profile button.
     1216 *
     1217 * @since 1.0.0
    11071218 */
    11081219function bp_edit_profile_button() {
     
    11241235 * Echo the field visibility radio buttons.
    11251236 *
    1126  * @param array|string $args Args for the radio buttons.
     1237 * @since 1.6.0
     1238 *
     1239 * @param array|string $args Args for the radio buttons. See {@link bp_profile_get_visibility_radio_buttons}
    11271240 */
    11281241function bp_profile_visibility_radio_buttons( $args = '' ) {
     
    11321245     * Return the field visibility radio buttons.
    11331246     *
    1134      * @param array|string $args Args for the radio buttons.
    1135      * @return string $retval
     1247     * @since 1.6.0
     1248     *
     1249     * @param array|string $args {
     1250     *    Args for the radio buttons.
     1251     *
     1252     *    @type int    $field_id     ID of the field to render.
     1253     *    @type string $before       Markup to render before the field.
     1254     *    @type string $after        Markup to render after the field.
     1255     *    @type string $before_radio Markup to render before the radio button.
     1256     *    @type string $after_radio  Markup to render after the radio button.
     1257     *    @type string $class        Class to apply to the field markup.
     1258     * }
     1259     * @return string $retval
    11361260     */
    11371261    function bp_profile_get_visibility_radio_buttons( $args = '' ) {
     
    12001324 * @since 2.0.0
    12011325 *
    1202  * @param array|string $args Args for the select list.
     1326 * @param array|string $args Args for the select list. See {@link bp_profile_get_settings_visibility_select}
    12031327 */
    12041328function bp_profile_settings_visibility_select( $args = '' ) {
     
    12101334     * @since 2.0.0
    12111335     *
    1212      * @param array|string $args Args for the select list.
     1336     * @param array|string $args {
     1337     *    Args for the select list.
     1338     *
     1339     *    @type int    $field_id ID of the field to render.
     1340     *    @type string $before   Markup to render before the field.
     1341     *    @type string $after    Markup to render after the field.
     1342     *    @type string $class    Class to apply to the field markup.
     1343     * }
    12131344     * @return string $retval
    12141345     */
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-component.php

    r10652 r10740  
    1616/**
    1717 * Creates our XProfile component.
     18 *
     19 * @since 1.5.0
    1820 */
    1921class BP_XProfile_Component extends BP_Component {
     
    3133     *
    3234     * @see bp_xprofile_get_visibility_levels()
     35     *
    3336     * @since 1.6.0
    3437     * @var array
     
    5659    /**
    5760     * Include files.
     61     *
     62     * @since 1.5.0
    5863     *
    5964     * @param array $includes Array of files to include.
     
    179184     * Set up navigation.
    180185     *
     186     * @since 1.5.0
     187     *
    181188     * @global BuddyPress $bp The one true BuddyPress instance
    182189     *
     
    302309     * Set up the Admin Bar.
    303310     *
     311     * @since 1.5.0
     312     *
    304313     * @param array $wp_admin_nav Admin Bar items.
    305314     */
     
    374383    /**
    375384     * Sets up the title for pages and <title>.
     385     *
     386     * @since 1.5.0
    376387     */
    377388    public function setup_title() {
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-data-template.php

    r10525 r10740  
    104104     * @see BP_XProfile_Group::get() for more details about parameters.
    105105     *
     106     * @since 1.5.0
    106107     * @since 2.4.0 Introduced `$member_type` argument.
    107108     *
     
    167168     * Whether or not the loop has field groups.
    168169     *
     170     * @since 1.0.0
     171     *
    169172     * @return bool
    170173     */
     
    179182    /**
    180183     * Increments to the next group of fields.
     184     *
     185     * @since 1.0.0
    181186     *
    182187     * @return object
     
    207212    /**
    208213     * Rewinds to the start of the groups list.
     214     *
     215     * @since 1.0.0
    209216     */
    210217    public function rewind_groups() {
     
    217224    /**
    218225     * Kicks off the profile groups.
     226     *
     227     * @since 1.0.0
    219228     *
    220229     * @return bool
     
    242251    /**
    243252     * Sets up the profile group.
     253     *
     254     * @since 1.0.0
    244255     */
    245256    public function the_profile_group() {
     
    266277     * Increments to the next field.
    267278     *
     279     * @since 1.0.0
     280     *
    268281     * @return int
    269282     */
     
    278291    /**
    279292     * Rewinds to the start of the fields.
     293     *
     294     * @since 1.0.0
    280295     */
    281296    public function rewind_fields() {
     
    289304     * Whether or not the loop has fields.
    290305     *
     306     * @since 1.0.0
     307     *
    291308     * @return bool
    292309     */
     
    307324    /**
    308325     * Kick off the profile fields.
     326     *
     327     * @since 1.0.0
    309328     *
    310329     * @return bool
     
    323342    /**
    324343     * Set up the profile fields.
     344     *
     345     * @since 1.0.0
    325346     */
    326347    public function the_profile_field() {
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-field-type-radiobutton.php

    r10713 r10740  
    1919
    2020    /**
    21      * Constructor for the radio button field type
     21     * Constructor for the radio button field type.
    2222     *
    2323     * @since 2.0.0
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-field.php

    r10657 r10740  
    1313/**
    1414 * Class to help set up XProfile fields.
     15 *
     16 * @since 1.0.0
    1517 */
    1618class BP_XProfile_Field {
     
    134136     *
    135137     * @since 2.5.0
    136      *
    137138     * @var bool
    138139     */
     
    215216    /**
    216217     * Retrieve a `BP_XProfile_Field` instance.
     218     *
     219     * @since 2.4.0
    217220     *
    218221     * @static
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-group.php

    r10720 r10740  
    1313/**
    1414 * Class to help set up XProfile Groups.
     15 *
     16 * @since 1.0.0
    1517 */
    1618class BP_XProfile_Group {
     
    2022     *
    2123     * @since 1.1.0
    22      * @var int ID of field group
     24     * @var int ID of field group.
    2325     */
    2426    public $id = null;
     
    2830     *
    2931     * @since 1.1.0
    30      * @var string Name of field group
     32     * @var string Name of field group.
    3133     */
    3234    public $name;
     
    3638     *
    3739     * @since 1.1.0
    38      * @var string Description of field group
     40     * @var string Description of field group.
    3941     */
    4042    public $description;
     
    5254     *
    5355     * @since 1.1.0
    54      * @var int Group order relative to other groups
     56     * @var int Group order relative to other groups.
    5557     */
    5658    public $group_order;
     
    6062     *
    6163     * @since 1.1.0
    62      * @var array Fields of group
     64     * @var array Fields of group.
    6365     */
    6466    public $fields;
     
    8587     *
    8688     * @param int $id Field group ID.
    87      *
    8889     * @return boolean
    8990     */
     
    232233    /**
    233234     * Populates the BP_XProfile_Group object with profile field groups, fields,
    234      * and field data
     235     * and field data.
     236     *
     237     * @since 1.2.0
    235238     *
    236239     * @global object $wpdb WordPress DB access object.
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-meta-query.php

    r10418 r10740  
    3333     *
    3434     * @param array $query Meta query arguments.
    35      *
    3635     * @return bool Whether the query clause is a first-order clause.
    3736     */
     
    4140
    4241    /**
    43      * Constructs a meta query based on 'meta_*' query vars
     42     * Constructs a meta query based on 'meta_*' query vars.
    4443     *
    4544     * @since 2.3.0
     
    101100     * @param string      $primary_id_column ID column for the filtered object in $primary_table.
    102101     * @param object|null $context           Optional. The main query object.
    103      *
    104102     * @return array {
    105103     *     Array containing JOIN and WHERE SQL clauses to append to the main query.
     
    160158     * @param string $clause_key   Optional. The array key used to name the clause in the original `$meta_query`
    161159     *                             parameters. If not provided, a key will be generated automatically.
    162      *
    163160     * @return array {
    164161     *     Array containing JOIN and WHERE SQL clauses to append to a first-order query.
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-profiledata.php

    r10434 r10740  
    2121     * XProfile ID.
    2222     *
     23     * @since 1.6.0
    2324     * @var int $id
    2425     */
     
    2829     * User ID.
    2930     *
     31     * @since 1.6.0
    3032     * @var int $user_id
    3133     */
     
    3537     * XProfile field ID.
    3638     *
     39     * @since 1.6.0
    3740     * @var int $field_id
    3841     */
     
    4245     * XProfile field value.
    4346     *
     47     * @since 1.6.0
    4448     * @var string $value
    4549     */
     
    4953     * XProfile field last updated time.
    5054     *
     55     * @since 1.6.0
    5156     * @var string $last_updated
    5257     */
     
    5661     * BP_XProfile_ProfileData constructor.
    5762     *
    58      * @param null $field_id Field ID to instantiate.
    59      * @param null $user_id  User ID to instantiate for.
     63     * @since 1.5.0
     64     *
     65     * @param int|null $field_id Field ID to instantiate.
     66     * @param int|null $user_id  User ID to instantiate for.
    6067     */
    6168    public function __construct( $field_id = null, $user_id = null ) {
     
    6774    /**
    6875     * Populates the XProfile profile data.
     76     *
     77     * @since 1.0.0
    6978     *
    7079     * @param int $field_id Field ID to populate.
     
    105114     * Check if there is data already for the user.
    106115     *
     116     * @since 1.0.0
     117     *
    107118     * @global object $wpdb
    108119     * @global array $bp
     120     *
    109121     * @return bool
    110122     */
     
    137149     * Check if this data is for a valid field.
    138150     *
     151     * @since 1.0.0
     152     *
    139153     * @global object $wpdb
     154     *
    140155     * @return bool
    141156     */
     
    160175    /**
    161176     * Save the data for the XProfile field.
     177     *
     178     * @since 1.0.0
    162179     *
    163180     * @return bool
     
    219236     * Delete specific XProfile field data.
    220237     *
     238     * @since 1.0.0
     239     *
    221240     * @global object $wpdb
     241     *
    222242     * @return boolean
    223243     */
     
    257277    /**
    258278     * Get a user's profile data for a set of fields.
     279     *
     280     * @since 2.0.0
    259281     *
    260282     * @param int   $user_id   ID of user whose data is being queried.
     
    324346     * Get all of the profile information for a specific user.
    325347     *
     348     * @since 1.2.0
     349     *
    326350     * @param int $user_id ID of the user.
    327351     * @return array
     
    369393     * Get the user's field data id by the id of the xprofile field.
    370394     *
     395     * @since 1.6.0
     396     *
    371397     * @param int $field_id Field ID being queried for.
    372398     * @param int $user_id  User ID associated with field.
     
    398424     *
    399425     * Supports multiple user IDs.
     426     *
     427     * @since 1.0.0
    400428     *
    401429     * @param int            $field_id ID of the field.
     
    479507     * Get profile field values by field name and user ID.
    480508     *
     509     * @since 1.0.0
     510     *
    481511     * @param array|string $fields  Field(s) to get.
    482512     * @param int|null     $user_id User ID to get field data for.
     
    541571     * Delete field.
    542572     *
     573     * @since 1.0.0
     574     *
    543575     * @param int $field_id ID of the field to delete.
    544576     * @return bool
     
    559591     * Get time for last XProfile field data update by user.
    560592     *
     593     * @since 1.0.0
     594     *
    561595     * @param int $user_id User ID to get time for.
    562596     * @return null|string
     
    575609     * Delete all data for provided user ID.
    576610     *
     611     * @since 1.0.0
     612     *
    577613     * @param int $user_id User ID to remove data for.
    578614     * @return false|int
     
    588624    /**
    589625     * Get random field type by user ID.
     626     *
     627     * @since 1.0.0
    590628     *
    591629     * @param int    $user_id          User ID to query for.
     
    606644     * Get fullname for provided user ID.
    607645     *
     646     * @since 1.0.0
     647     *
    608648     * @param int $user_id ID of the user to query.
    609649     * @return mixed
  • trunk/src/bp-xprofile/classes/class-bp-xprofile-user-admin.php

    r10525 r10740  
    144144            endwhile;
    145145
    146         // If member is already a spammer, show a generic metabox.
     146
    147147        } else {
     148            // If member is already a spammer, show a generic metabox.
    148149            add_meta_box(
    149150                'bp_xprofile_user_admin_empty_profile',
     
    199200            bp_core_redirect( $redirect_to );
    200201
    201         // Update profile fields.
    202202        } elseif ( isset( $_POST['field_ids'] ) ) {
    203 
     203            // Update profile fields.
    204204            // Check the nonce.
    205205            check_admin_referer( 'edit-bp-profile_' . $user_id );
Note: See TracChangeset for help on using the changeset viewer.