phpBB API Documentation
Class

custom_profile_admin

class custom_profile_admin extends custom_profile

Custom Profile Fields ACP

Properties

$profile_types
$profile_cache
$options_lang
$vars

Methods

generate_profile_fields($mode, $lang_id)

Assign editable fields to template, mode can be profile (for profile change) or register (for registration) Called by ucpprofile and ucpregister

from custom_profile
validate_profile_field($field_type, $field_value, $field_data)

Validate entered profile field data

from custom_profile
build_cache()

Build profile cache, used for display

from custom_profile
get_option_lang($field_id, $lang_id, $field_type, $preview)

Get language entries for options and store them here for later use

from custom_profile
submit_cp_field($mode, $lang_id, $cp_data, $cp_error)

Submit profile field for validation

from custom_profile
update_profile_field_data($user_id, $cp_data)

Update profile field data directly

from custom_profile
generate_profile_fields_template($mode, $user_id, $profile_row = false)

Assign fields to template, used for viewprofile, viewtopic and memberlist (if load setting is enabled) This is directly connected to the user -> mode == grab is to grab the user specific fields, mode == show is for assigning the row to the template

from custom_profile
get_profile_value($ident_ary)

Get Profile Value for display

from custom_profile
get_var($field_validation, $profile_row, $default_value, $preview)

Get field value for registration/profile

from custom_profile
generate_int($profile_row, $preview = false)

Process int-type

from custom_profile
generate_date($profile_row, $preview = false)

Process date-type

from custom_profile
generate_bool($profile_row, $preview = false)

Process bool-type

from custom_profile
generate_string($profile_row, $preview = false)

Process string-type

from custom_profile
generate_text($profile_row, $preview = false)

Process text-type

from custom_profile
generate_dropdown($profile_row, $preview = false)

Process dropdown-type

from custom_profile
process_field_row($mode, $profile_row)

Return Templated value/field.

from custom_profile
build_insert_sql_array($cp_data)

Build Array for user insertion into custom profile fields table

from custom_profile
get_profile_field($profile_row)

Get profile field value on submit

from custom_profile
validate_options()

Return possible validation options

get_string_options()

Get string options for second step in ACP

get_text_options()

Get text options for second step in ACP

get_int_options()

Get int options for second step in ACP

get_bool_options()

Get bool options for second step in ACP

get_dropdown_options()

Get dropdown options for second step in ACP

get_date_options()

Get date options for second step in ACP

Details

in custom_profile at line 34
public generate_profile_fields($mode, $lang_id)

Assign editable fields to template, mode can be profile (for profile change) or register (for registration) Called by ucpprofile and ucpregister

Parameters

$mode
$lang_id

in custom_profile at line 91
public validate_profile_field($field_type, $field_value, $field_data)

Validate entered profile field data

Parameters

$field_type
$field_value
$field_data

in custom_profile at line 208
public build_cache()

Build profile cache, used for display

in custom_profile at line 235
public get_option_lang($field_id, $lang_id, $field_type, $preview)

Get language entries for options and store them here for later use

Parameters

$field_id
$lang_id
$field_type
$preview

in custom_profile at line 270
public submit_cp_field($mode, $lang_id, $cp_data, $cp_error)

Submit profile field for validation

Parameters

$mode
$lang_id
$cp_data
$cp_error

in custom_profile at line 361
public update_profile_field_data($user_id, $cp_data)

Update profile field data directly

Parameters

$user_id
$cp_data

in custom_profile at line 424
public generate_profile_fields_template($mode, $user_id, $profile_row = false)

Assign fields to template, used for viewprofile, viewtopic and memberlist (if load setting is enabled) This is directly connected to the user -> mode == grab is to grab the user specific fields, mode == show is for assigning the row to the template

Parameters

$mode
$user_id
$profile_row

in custom_profile at line 527
public get_profile_value($ident_ary)

Get Profile Value for display

Parameters

$ident_ary

in custom_profile at line 645
public get_var($field_validation, $profile_row, $default_value, $preview)

Get field value for registration/profile

Parameters

$field_validation
$profile_row
$default_value
$preview

in custom_profile at line 704
public generate_int($profile_row, $preview = false)

Process int-type

Parameters

$profile_row
$preview

in custom_profile at line 716
public generate_date($profile_row, $preview = false)

Process date-type

Parameters

$profile_row
$preview

in custom_profile at line 775
public generate_bool($profile_row, $preview = false)

Process bool-type

Parameters

$profile_row
$preview

in custom_profile at line 806
public generate_string($profile_row, $preview = false)

Process string-type

Parameters

$profile_row
$preview

in custom_profile at line 818
public generate_text($profile_row, $preview = false)

Process text-type

Parameters

$profile_row
$preview

in custom_profile at line 835
public generate_dropdown($profile_row, $preview = false)

Process dropdown-type

Parameters

$profile_row
$preview

in custom_profile at line 864
public process_field_row($mode, $profile_row)

Return Templated value/field.

Possible values for $mode are: change == user is able to set/enter profile values; preview == just show the value

Parameters

$mode
$profile_row

in custom_profile at line 892
public build_insert_sql_array($cp_data)

Build Array for user insertion into custom profile fields table

Parameters

$cp_data

in custom_profile at line 933
public get_profile_field($profile_row)

Get profile field value on submit

Parameters

$profile_row

at line 1015
public validate_options()

Return possible validation options

at line 1034
public get_string_options()

Get string options for second step in ACP

at line 1051
public get_text_options()

Get text options for second step in ACP

at line 1068
public get_int_options()

Get int options for second step in ACP

at line 1085
public get_bool_options()

Get bool options for second step in ACP

at line 1115
public get_dropdown_options()

Get dropdown options for second step in ACP

at line 1149
public get_date_options()

Get date options for second step in ACP