public function display_field_profile(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $value = FormatingHelper::second_parse($member_extended_field->get_value());
     if ($value !== null) {
         $fieldset->add_field(new FormFieldFree($member_extended_field->get_field_name(), $member_extended_field->get_name(), $value));
     }
 }
 public function display_field_profile(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $value = $member_extended_field->get_value();
     if ($value !== null) {
         $fieldset->add_field(new FormFieldFree($member_extended_field->get_field_name(), $member_extended_field->get_name(), $this->get_picture_sex($value)));
     }
 }
 public function display_field_profile(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     if ($member_extended_field->get_value()) {
         $date = new Date($member_extended_field->get_value());
         $fieldset->add_field(new FormFieldFree($member_extended_field->get_field_name(), $member_extended_field->get_name(), $date->format(Date::FORMAT_DAY_MONTH_YEAR)));
     }
 }
 /**
  * {@inheritdoc}
  */
 public function display_field_profile(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $value = $member_extended_field->get_value();
     if (!empty($value)) {
         $fieldset->add_field(new FormFieldFree($member_extended_field->get_field_name(), $member_extended_field->get_name(), $value));
     }
 }
 public function display_field_update(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $streams = $this->get_streams();
     if (!empty($streams)) {
         $newsletter_subscribe = NewsletterService::get_member_id_streams($member_extended_field->get_user_id());
         $fieldset->add_field(new FormFieldMultipleCheckbox($member_extended_field->get_field_name(), $member_extended_field->get_name(), $newsletter_subscribe, $streams, array('description' => $member_extended_field->get_description())));
     }
 }
 public function display_field_update(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $options = array();
     $default_values = explode('|', $member_extended_field->get_value());
     foreach ($member_extended_field->get_possible_values() as $name => $parameters) {
         $options[] = new FormFieldMultipleCheckboxOption($name, stripslashes($parameters['title']));
     }
     $fieldset->add_field(new FormFieldMultipleCheckbox($member_extended_field->get_field_name(), $member_extended_field->get_name(), $default_values, $options, array('required' => (bool) $member_extended_field->get_required(), 'description' => $member_extended_field->get_description())));
 }
 public function display_field_update(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $options = array();
     $default = $member_extended_field->get_value();
     foreach ($member_extended_field->get_possible_values() as $name => $parameters) {
         $options[] = new FormFieldRadioChoiceOption(stripslashes($parameters['title']), $name);
     }
     if (empty($default)) {
         $options = array_merge(array(new FormFieldSelectChoiceOption('', '')), $options);
         $default = '';
     }
     $fieldset->add_field(new FormFieldRadioChoice($member_extended_field->get_field_name(), $member_extended_field->get_name(), $default, $options, array('required' => (bool) $member_extended_field->get_required(), 'description' => $member_extended_field->get_description())));
 }
 public function display_field_profile(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $user_accounts_config = UserAccountsConfig::load();
     $value = $member_extended_field->get_value();
     if (empty($value) && $user_accounts_config->is_default_avatar_enabled()) {
         $avatar = '<img src="' . Url::to_rel('/templates/' . AppContext::get_current_user()->get_theme() . '/images/' . $user_accounts_config->get_default_avatar_name()) . '" alt="' . LangLoader::get_message('avatar', 'user-common') . '" title="' . LangLoader::get_message('avatar', 'user-common') . '" />';
     } elseif (!empty($value)) {
         $avatar = '<img src="' . Url::to_rel($value) . '" alt="' . LangLoader::get_message('avatar', 'user-common') . '" title="' . LangLoader::get_message('avatar', 'user-common') . '" />';
     } else {
         $avatar = $this->lang['extended-field.field.avatar.no_avatar'];
     }
     if (!empty($avatar)) {
         $fieldset->add_field(new FormFieldFree($member_extended_field->get_field_name(), $member_extended_field->get_name(), $avatar));
     }
 }
 public function display_field_update(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $fieldset->add_field(new FormFieldCheckbox($member_extended_field->get_field_name(), $member_extended_field->get_name(), $member_extended_field->get_value(), array('description' => $member_extended_field->get_description(), 'required' => (bool) $member_extended_field->get_required())));
 }
 public function display_field_update(MemberExtendedField $member_extended_field)
 {
     $fieldset = $member_extended_field->get_fieldset();
     $fieldset->add_field(new FormFieldShortMultiLineTextEditor($member_extended_field->get_field_name(), $member_extended_field->get_name(), $member_extended_field->get_value(), array('required' => (bool) $member_extended_field->get_required(), 'rows' => 4, 'cols' => 47, 'description' => $member_extended_field->get_description()), array($this->constraint($member_extended_field->get_regex()))));
 }