29                include_once 
'./Services/User/classes/class.ilUserDefinedFields.php';
 
   36                $this->
settings = $ilias->getAllSettings();
 
   37                $lng->loadLanguageModule(
"jsmath");
 
   38                $lng->loadLanguageModule(
"pd");
 
   39                $this->upload_error = 
"";
 
   40                $this->password_error = 
"";
 
   41                $lng->loadLanguageModule(
"user");
 
   52                $next_class = $this->ctrl->getNextClass();
 
   56                        case "ilpublicuserprofilegui":
 
   57                                include_once(
"./Services/User/classes/class.ilPublicUserProfileGUI.php");
 
   60                                $pub_profile_gui->setBackUrl(
$ilCtrl->getLinkTarget($this, 
"showPersonalData"));
 
   61                                $ilCtrl->forwardCommand($pub_profile_gui);
 
   67                                $cmd = $this->ctrl->getCmd(
"showPersonalData");                                                 
 
   82                if ($this->
settings[
"usr_settings_hide_".$setting] == 1)
 
   86                if ($this->
settings[
"usr_settings_disable_".$setting] == 1)
 
  100                if (isset($this->
settings[
"usr_settings_hide_".$setting]) &&
 
  101                        $this->
settings[
"usr_settings_hide_".$setting] == 1)
 
  115                if ($this->
settings[
"usr_settings_disable_".$setting] == 1)
 
  131                        if (!$this->form->hasFileUpload(
"userfile"))
 
  133                                if ($this->form->getItemByPostVar(
"userfile")->getDeletionFlag())
 
  142                                $image_dir = $webspace_dir.
"/usr_images";
 
  143                                $store_file = 
"usr_".$ilUser->getID().
".".
"jpg";
 
  146                                $ilUser->setPref(
"profile_image", $store_file);
 
  151                                $pi = pathinfo($_FILES[
"userfile"][
"name"]);
 
  152                                $uploaded_file = $this->form->moveFileUpload($image_dir, 
 
  153                                        "userfile", 
"upload_".
$ilUser->getId().
".".$pi[
"extension"]);
 
  157                                        $this->ctrl->redirect($this, 
"showProfile");
 
  159                                chmod($uploaded_file, 0770);
 
  163                                $show_file  = 
"$image_dir/usr_".$ilUser->getId().
".jpg";
 
  164                                $thumb_file = 
"$image_dir/usr_".$ilUser->getId().
"_small.jpg";
 
  165                                $xthumb_file = 
"$image_dir/usr_".$ilUser->getId().
"_xsmall.jpg";
 
  166                                $xxthumb_file = 
"$image_dir/usr_".$ilUser->getId().
"_xxsmall.jpg";
 
  175                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 200x200^ -gravity center -extent 200x200 -quality 100 JPEG:".$show_file);
 
  176                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 100x100^ -gravity center -extent 100x100 -quality 100 JPEG:".$thumb_file);
 
  177                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 75x75^ -gravity center -extent 75x75 -quality 100 JPEG:".$xthumb_file);
 
  178                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 30x30^ -gravity center -extent 30x30 -quality 100 JPEG:".$xxthumb_file);
 
  182                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 200x200 -quality 100 JPEG:".$show_file);
 
  183                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 100x100 -quality 100 JPEG:".$thumb_file);
 
  184                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 75x75 -quality 100 JPEG:".$xthumb_file);
 
  185                                        ilUtil::execConvert($uploaded_file . 
"[0] -geometry 30x30 -quality 100 JPEG:".$xxthumb_file);
 
  221                if ((
$_POST[
"chk_pub"])==
"on")
 
  223                        $ilUser->setPref(
"public_profile",
"y");
 
  227                        $ilUser->setPref(
"public_profile",
"n");
 
  231                $val_array = array(
"institution", 
"department", 
"upload", 
"street",
 
  232                        "zip", 
"city", 
"country", 
"phone_office", 
"phone_home", 
"phone_mobile",
 
  233                        "fax", 
"email", 
"hobby", 
"matriculation");
 
  236                foreach($val_array as $key => $value)
 
  238                        if ((
$_POST[
"chk_".$value]) == 
"on")
 
  240                                $ilUser->setPref(
"public_".$value,
"y");
 
  244                                $ilUser->setPref(
"public_".$value,
"n");
 
  249                foreach($this->
settings as $key => $val)
 
  251                        if (substr($key,0,8) == 
"require_")
 
  253                                $require_keys[] = substr($key,8);
 
  257                foreach($require_keys as $key => $val)
 
  260                        $system_fields = array(
"login", 
"default_role", 
"passwd", 
"passwd2");
 
  261                        if (!in_array($val, $system_fields))
 
  265                                        if (isset($this->
settings[
"require_" . $val]) && $this->
settings[
"require_" . $val])
 
  267                                                if (empty(
$_POST[
"usr_" . $val]))
 
  269                                                        ilUtil::sendFailure($this->lng->txt(
"fill_out_all_required_fields") . 
": " . $this->lng->txt($val));
 
  305                        $ilUser->setGender(
$_POST[
"usr_gender"]);
 
  381                                if (
$_POST[
"usr_skin_style"] != 
"")
 
  383                                        $sknst = explode(
":", 
$_POST[
"usr_skin_style"]);
 
  385                                        if (
$ilUser->getPref(
"style") != $sknst[1] ||
 
  386                                                $ilUser->getPref(
"skin") != $sknst[0])
 
  388                                                $ilUser->setPref(
"skin", $sknst[0]);
 
  389                                                $ilUser->setPref(
"style", $sknst[1]);
 
  400                                if (
$_POST[
"usr_language"] != $ilUser->getLanguage())
 
  412                                if (
$_POST[
"hits_per_page"] != 
"")
 
  414                                        $ilUser->setPref(
"hits_per_page",
$_POST[
"hits_per_page"]);
 
  427                                if (
$_POST[
"chk_hide_own_online_status"] != 
"")
 
  429                                        $ilUser->setPref(
"hide_own_online_status",
"y");
 
  433                                        $ilUser->setPref(
"hide_own_online_status",
"n");
 
  450                        $ilUser->setProfileIncomplete(
false);
 
  459                        include_once 
'./Services/Search/classes/Lucene/class.ilLuceneIndexer.php';
 
  465                        if (!empty($this->password_error))
 
  469                        elseif (!empty($this->upload_error))
 
  477                                $this->ctrl->redirect($this, 
"");
 
  509                include_once(
"./Services/Maps/classes/class.ilMapUtil.php");
 
  516                $this->lng->loadLanguageModule(
"maps");
 
  524                if ($latitude == 0 && $longitude == 0 && $zoom == 0)
 
  527                        $latitude = $def[
"latitude"];
 
  528                        $longitude = $def[
"longitude"];
 
  529                        $zoom =  $def[
"zoom"];
 
  535                        $street = $this->lng->txt(
"street");
 
  540                        $city = $this->lng->txt(
"city");
 
  545                        $country = $this->lng->txt(
"country");
 
  551                $loc_prop->setLatitude($latitude);
 
  552                $loc_prop->setLongitude($longitude);
 
  553                $loc_prop->setZoom($zoom);
 
  554                $loc_prop->setAddress($street.
",".$city.
",".$country);
 
  562                global $ilTabs, 
$ilUser, $ilHelp;
 
  564                $ilHelp->setScreenIdComponent(
"user");
 
  567                $ilTabs->addTab(
"personal_data", 
 
  568                        $this->lng->txt(
"personal_data"),
 
  569                        $this->ctrl->getLinkTarget($this, 
"showPersonalData"));
 
  572                $ilTabs->addTab(
"public_profile",
 
  573                        $this->lng->txt(
"public_profile"),
 
  574                        $this->ctrl->getLinkTarget($this, 
"showPublicProfile"));
 
  577                $ilTabs->addTab(
"export",
 
  578                        $this->lng->txt(
"export").
"/".$this->lng->txt(
"import"),
 
  579                        $this->ctrl->getLinkTarget($this, 
"showExportImport"));
 
  582                if((
$ilUser->getPref(
"public_profile") && 
 
  583                        $ilUser->getPref(
"public_profile") != 
"n") || 
 
  584                        $this->getProfilePortfolio())
 
  587                        $ilTabs->addNonTabbedLink(
"profile_preview",
 
  588                                $this->lng->txt(
"user_profile_preview"),
 
  589                                $this->ctrl->getLinkTargetByClass(
"ilpublicuserprofilegui", 
"view"));
 
  597                if($this->
userSettingVisible(
"matriculation") or count($this->user_defined_fields->getVisibleDefinitions())
 
  598                        or $d_set->get(
"user_profile") == 
"1")
 
  609                $user_defined_data = 
$ilUser->getUserDefinedData();
 
  610                foreach($this->user_defined_fields->getVisibleDefinitions() as $field_id => $definition)
 
  614                                $this->tpl->setCurrentBlock(
"field_text");
 
  616                                if(!$definition[
'changeable'])
 
  618                                        $this->tpl->setVariable(
"DISABLED_FIELD",
'disabled=\"disabled\"');
 
  619                                        $this->tpl->setVariable(
"FIELD_NAME",
'udf['.$definition[
'field_id'].
']');
 
  623                                        $this->tpl->setVariable(
"FIELD_NAME",
'udf['.$definition[
'field_id'].
']');
 
  625                                $this->tpl->parseCurrentBlock();
 
  629                                if($definition[
'changeable'])
 
  631                                        $name = 
'udf['.$definition[
'field_id'].
']';
 
  639                                $this->tpl->setCurrentBlock(
"field_select");
 
  640                                $this->tpl->setVariable(
"SELECT_BOX",
ilUtil::formSelect($user_defined_data[$field_id],
 
  642                                                                                                                                                $this->user_defined_fields->fieldValuesToSelectArray(
 
  643                                                                                                                                                        $definition[
'field_values']),
 
  645                                                                                                                                                true,0,
'',
'',$disabled));
 
  646                                $this->tpl->parseCurrentBlock();
 
  648                        $this->tpl->setCurrentBlock(
"user_defined");
 
  650                        if($definition[
'required'])
 
  652                                $name = $definition[
'field_name'].
"<span class=\"asterisk\">*</span>";
 
  656                                $name = $definition[
'field_name'];
 
  658                        $this->tpl->setVariable(
"TXT_FIELD_NAME",$name);
 
  659                        $this->tpl->parseCurrentBlock();
 
  666                foreach($this->user_defined_fields->getVisibleDefinitions() as $definition)
 
  668                        $field_id = $definition[
'field_id'];
 
  669                        if($definition[
'required'] and !strlen(
$_POST[
'udf'][$field_id]))
 
  682                $this->tpl->setTitle($this->lng->txt(
'personal_profile'));
 
  698                $ilTabs->activateTab(
"personal_data");
 
  700                $settings = 
$ilias->getAllSettings();
 
  708                        if ($ilUser->getProfileIncomplete())
 
  713                $this->tpl->setContent($this->form->getHTML());
 
  725                include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
 
  727                $this->form->setFormAction($this->ctrl->getFormAction($this));
 
  730                $user_defined_data = 
$ilUser->getUserDefinedData();
 
  732                foreach($this->user_defined_fields->getVisibleDefinitions() as $field_id => $definition)
 
  736                                $this->
input[
"udf_".$definition[
'field_id']] =
 
  737                                        new ilTextInputGUI($definition[
'field_name'], 
"udf_".$definition[
'field_id']);
 
  738                                $this->
input[
"udf_".$definition[
'field_id']]->setMaxLength(255);
 
  739                                $this->
input[
"udf_".$definition[
'field_id']]->setSize(40);
 
  743                                $this->
input[
"udf_".$definition[
'field_id']] =
 
  745                                $this->
input[
"udf_".$definition[
'field_id']]->setUseRte(
true);
 
  749                                $options = $this->user_defined_fields->fieldValuesToSelectArray($definition[
'field_values']);
 
  750                                $this->
input[
"udf_".$definition[
'field_id']] =
 
  751                                        new ilSelectInputGUI($definition[
'field_name'], 
"udf_".$definition[
'field_id']);
 
  752                                $this->
input[
"udf_".$definition[
'field_id']]->setOptions(
$options);
 
  755                        $value = $user_defined_data[
"f_".$field_id];
 
  756                        $this->
input[
"udf_".$definition[
'field_id']]->setValue($value);
 
  758                        if($definition[
'required'])
 
  760                                $this->
input[
"udf_".$definition[
'field_id']]->setRequired(
true);
 
  762                        if(!$definition[
'changeable'] && (!$definition[
'required'] || $value))
 
  764                                $this->
input[
"udf_".$definition[
'field_id']]->setDisabled(
true);
 
  771                                $this->
input[
"udf_".$definition[
'field_id']]->setOptions(
$options);
 
  776                include_once(
"./Services/User/classes/class.ilUserProfile.php");
 
  778                $up->skipField(
"password");
 
  779                $up->skipGroup(
"settings");
 
  780                $up->skipGroup(
"preferences");
 
  782                $up->setAjaxCallback(
 
  783                        $this->ctrl->getLinkTargetByClass(
'ilPublicUserProfileGUI', 
'doProfileAutoComplete', 
'', 
true)
 
  787                $up->addStandardFieldsToForm($this->form, 
$ilUser, $this->
input);
 
  791                $this->form->addCommandButton(
"savePersonalData", 
$lng->txt(
"save"));
 
  804                if ($this->form->checkInput())
 
  810                                "firstname" => 
"FirstName",
 
  811                                "lastname" => 
"LastName",
 
  813                                "sel_country" => 
"SelectedCountry",
 
  814                                "phone_office" => 
"PhoneOffice",
 
  815                                "phone_home" => 
"PhoneHome",
 
  816                                "phone_mobile" => 
"PhoneMobile",
 
  817                                "referral_comment" => 
"Comment",
 
  818                                "interests_general" => 
"GeneralInterests",
 
  819                                "interests_help_offered" => 
"OfferingHelp",
 
  820                                "interests_help_looking" => 
"LookingForHelp" 
  822                        include_once(
"./Services/User/classes/class.ilUserProfile.php");
 
  824                        foreach($up->getStandardFields() as $f => $p)
 
  827                                $item = $this->form->getItemByPostVar(
"usr_".$f);
 
  828                                if($item && !$item->getDisabled())
 
  830                                        $value = $this->form->getInput(
"usr_".$f);                                      
 
  834                                                        $value = $item->getDate();
 
  854                        include_once(
"./Services/Maps/classes/class.ilMapUtil.php");
 
  858                                $location = $this->form->getInput(
"location");
 
  862                                $ilUser->setLatitude(is_numeric($lat) ? $lat : 
null);
 
  863                                $ilUser->setLongitude(is_numeric($long) ? $long : 
null);
 
  864                                $ilUser->setLocationZoom(is_numeric($zoom) ? $zoom : 
null);
 
  868                        $defs = $this->user_defined_fields->getVisibleDefinitions();
 
  870                        foreach ($defs as $definition)
 
  872                                $f = 
"udf_".$definition[
'field_id'];
 
  873                                $item = $this->form->getItemByPostVar($f);
 
  874                                if ($item && !$item->getDisabled())
 
  876                                        $udf[$definition[
'field_id']] = $this->form->getInput($f);
 
  879                        $ilUser->setUserDefinedData($udf);
 
  882                        $un = $this->form->getInput(
'username');
 
  883                        if((
int)
$ilSetting->get(
'allow_change_loginname') && 
 
  889                                        $this->form->getItemByPostVar(
'username')->setAlert($this->lng->txt(
'login_invalid'));
 
  895                                        $this->form->getItemByPostVar(
'username')->setAlert($this->lng->txt(
'loginname_already_exists'));
 
  909                                                $this->form->getItemByPostVar(
'username')->setAlert($e->getMessage());
 
  921                                $ilUser->setProfileIncomplete(
false);
 
  937                                else if($redirect = 
$_SESSION[
'profile_complete_redirect'])
 
  939                                        unset(
$_SESSION[
'profile_complete_redirect']);
 
  944                                        $ilCtrl->redirect($this, 
"showPersonalData");
 
  949                $this->form->setValuesByPost();
 
  966                $ilTabs->activateTab(
"public_profile");
 
  972                        $this->initPublicProfileForm();
 
  975                $ptpl = 
new ilTemplate(
"tpl.edit_personal_profile.html", 
true, 
true, 
"Services/User");
 
  976                $ptpl->setVariable(
"FORM", $this->form->getHTML());
 
  977                include_once(
"./Services/User/classes/class.ilPublicUserProfileGUI.php");
 
  979                $ptpl->setVariable(
"PREVIEW", $pub_profile->getEmbeddable());
 
  980                $this->tpl->setContent($ptpl->get());
 
  995                        include_once 
"Modules/Portfolio/classes/class.ilObjPortfolio.php";
 
 1009                include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
 
 1012                $this->form->setTitle(
$lng->txt(
"public_profile"));
 
 1013                $this->form->setDescription(
$lng->txt(
"user_public_profile_info"));
 
 1014                $this->form->setFormAction($this->ctrl->getFormAction($this));
 
 1016                $portfolio_id = $this->getProfilePortfolio();
 
 1022                        $info = $this->lng->txt(
"user_activate_public_profile_info");
 
 1023                        $pub_prof = in_array(
$ilUser->prefs[
"public_profile"], array(
"y", 
"n", 
"g"))
 
 1024                                ? 
$ilUser->prefs[
"public_profile"]
 
 1026                        if (!
$ilSetting->get(
'enable_global_profiles') && $pub_prof == 
"g")
 
 1030                        $radg->setValue($pub_prof);
 
 1031                                $op1 = 
new ilRadioOption(
$lng->txt(
"usr_public_profile_disabled"), 
"n",
$lng->txt(
"usr_public_profile_disabled_info"));
 
 1032                                $radg->addOption($op1);
 
 1034                                $radg->addOption($op2);
 
 1035                        if (
$ilSetting->get(
'enable_global_profiles'))
 
 1038                                $radg->addOption($op3);
 
 1040                        $this->form->addItem($radg);
 
 1046                                $prtf = 
"<br />".$lng->txt(
"user_profile_portfolio");
 
 1047                                $prtf .= 
"<br /><a href=\"ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToPortfolio\">» ".
 
 1048                                        $lng->txt(
"user_portfolios").
"</a>";    
 
 1052                        $radg->setInfo(
$info);
 
 1056                        $prtf = 
$lng->txt(
"user_profile_portfolio_selected");
 
 1057                        $prtf .= 
"<br /><a href=\"ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToPortfolio&prt_id=".$portfolio_id.
"\">» ".
 
 1058                                $lng->txt(
"portfolio").
"</a>";
 
 1061                        $info->setHTML($prtf);                  
 
 1062                        $this->form->addItem(
$info);
 
 1065                $this->showPublicProfileFields($this->form, 
$ilUser->prefs);
 
 1067                $this->form->addCommandButton(
"savePublicProfile", 
$lng->txt(
"save"));
 
 1082                $birthday = 
$ilUser->getBirthday();
 
 1087                $gender = 
$ilUser->getGender();
 
 1090                        $gender = $this->lng->txt(
"gender_".$gender);
 
 1093                if (
$ilUser->getSelectedCountry() != 
"")
 
 1095                        $this->lng->loadLanguageModule(
"meta");
 
 1096                        $txt_sel_country = $this->lng->txt(
"meta_c_".
$ilUser->getSelectedCountry());
 
 1103                        $pic = 
"<img src=\"".$pic.
"\" />";
 
 1108                        "title" => 
$ilUser->getUTitle(),
 
 1109                        "birthday" => $birthday,
 
 1110                        "gender" => $gender,
 
 1112                        "interests_general" => 
$ilUser->getGeneralInterestsAsText(),
 
 1113                        "interests_help_offered" => 
$ilUser->getOfferingHelpAsText(),
 
 1114                        "interests_help_looking" => 
$ilUser->getLookingForHelpAsText(),
 
 1115                        "org_units" => 
$ilUser->getOrgUnitsRepresentation(),
 
 1116                        "institution" => 
$ilUser->getInstitution(),
 
 1117                        "department" => 
$ilUser->getDepartment(),                       
 
 1118                        "street" => 
$ilUser->getStreet(),
 
 1119                        "zipcode" => 
$ilUser->getZipcode(),
 
 1121                        "country" => 
$ilUser->getCountry(),
 
 1122                        "sel_country" => $txt_sel_country,
 
 1123                        "phone_office" => 
$ilUser->getPhoneOffice(),
 
 1124                        "phone_home" => 
$ilUser->getPhoneHome(),
 
 1125                        "phone_mobile" => 
$ilUser->getPhoneMobile(),
 
 1127                        "email" => 
$ilUser->getEmail(),
 
 1128                        "hobby" => 
$ilUser->getHobby(),
 
 1129                        "matriculation" => 
$ilUser->getMatriculation()
 
 1133                include_once(
"./Services/Maps/classes/class.ilMapUtil.php");
 
 1136                        $val_array[
"location"] = 
"";
 
 1139                foreach($val_array as $key => $value)
 
 1146                        if ($this->userSettingVisible($key))
 
 1152                                                $caption = 
"personal_picture";
 
 1156                                                $caption = 
"person_title";
 
 1163                                if ($prefs[
"public_".$key] == 
"y")
 
 1165                                        $cb->setChecked(
true);
 
 1168                                $cb->setOptionTitle($value);
 
 1172                                        $form->addItem($cb);
 
 1176                                        $parent->addSubItem($cb);
 
 1182                $user_defined_data = array();
 
 1185                        $user_defined_data = 
$ilUser->getUserDefinedData();
 
 1187                foreach($this->user_defined_fields->getVisibleDefinitions() as $field_id => $definition)
 
 1190                        $cb = 
new ilCheckboxInputGUI($definition[
"field_name"], 
"chk_udf_".$definition[
"field_id"]);
 
 1191                        $cb->setOptionTitle($user_defined_data[
"f_".$definition[
"field_id"]]);
 
 1192                        if ($prefs[
"public_udf_".$definition[
"field_id"]] == 
"y")
 
 1194                                $cb->setChecked(
true);
 
 1199                                $form->addItem($cb);
 
 1203                                $parent->addSubItem($cb);
 
 1210                        include_once 
"Services/Badge/classes/class.ilBadgeHandler.php";
 
 1212                        if($handler->isActive())
 
 1214                                $badge_options = array();
 
 1216                                include_once 
"Services/Badge/classes/class.ilBadgeAssignment.php";
 
 1217                                include_once 
"Services/Badge/classes/class.ilBadge.php";
 
 1221                                        if($ass->getPosition())
 
 1223                                                $badge = 
new ilBadge($ass->getBadgeId());
 
 1224                                                $badge_options[] = $badge->getTitle();
 
 1228                                if(
sizeof($badge_options) > 1)
 
 1231                                        $badge_order->setMultiValues($badge_options);
 
 1232                                        $badge_order->setValue(array_shift($badge_options));
 
 1233                                        $badge_order->setMulti(
true, 
true, 
false);
 
 1237                                                $form->addItem($badge_order);
 
 1241                                                $parent->addSubItem($badge_order);
 
 1256                $this->initPublicProfileForm();
 
 1257                if ($this->form->checkInput())
 
 1260                        if(isset(
$_POST[
"public_profile"]))
 
 1262                                $ilUser->setPref(
"public_profile", 
$_POST[
"public_profile"]);
 
 1266                        $val_array = array(
"title", 
"birthday", 
"gender", 
"org_units", 
"institution", 
"department", 
"upload",
 
 1267                                "street", 
"zipcode", 
"city", 
"country", 
"sel_country", 
"phone_office", 
"phone_home", 
"phone_mobile",
 
 1268                                "fax", 
"email", 
"hobby", 
"matriculation", 
"location",
 
 1269                                "interests_general", 
"interests_help_offered", 
"interests_help_looking");
 
 1272                        foreach($val_array as $key => $value)
 
 1274                                if ((
$_POST[
"chk_".$value]))
 
 1276                                        $ilUser->setPref(
"public_".$value,
"y");
 
 1280                                        $ilUser->setPref(
"public_".$value,
"n");
 
 1285                        foreach($this->user_defined_fields->getVisibleDefinitions() as $field_id => $definition)
 
 1287                                if ((
$_POST[
"chk_udf_".$definition[
"field_id"]]))
 
 1289                                        $ilUser->setPref(
"public_udf_".$definition[
"field_id"], 
"y");
 
 1293                                        $ilUser->setPref(
"public_udf_".$definition[
"field_id"], 
"n");
 
 1300                        include_once 
"Services/Badge/classes/class.ilBadgeHandler.php";
 
 1302                        if($handler->isActive())
 
 1304                                if(
sizeof(
$_POST[
"bpos"]))
 
 1306                                        include_once 
"Services/Badge/classes/class.ilBadgeAssignment.php";
 
 1312                        include_once 
'./Services/Search/classes/Lucene/class.ilLuceneIndexer.php';
 
 1316                        $ilCtrl->redirect($this, 
"showPublicProfile");
 
 1318                $this->form->setValuesByPost();
 
 1319                $tpl->showPublicProfile(
true);
 
 1335                $ilTabs->activateTab(
"export");
 
 1338                include_once 
"Services/UIComponent/Button/classes/class.ilLinkButton.php";
 
 1340                $button->setCaption(
"pd_export_profile");
 
 1341                $button->setUrl(
$ilCtrl->getLinkTarget($this, 
"exportPersonalData"));                   
 
 1342                $ilToolbar->addStickyItem($button);
 
 1344                $exp_file = 
$ilUser->getPersonalDataExportFile();
 
 1345                if ($exp_file != 
"")
 
 1347                        $ilToolbar->addSeparator();
 
 1348                        $ilToolbar->addButton($this->lng->txt(
"pd_download_last_export_file"),
 
 1349                                $ilCtrl->getLinkTarget($this, 
"downloadPersonalData"));
 
 1352                $ilToolbar->addSeparator();
 
 1353                $ilToolbar->addButton($this->lng->txt(
"pd_import_personal_data"),
 
 1354                        $ilCtrl->getLinkTarget($this, 
"importPersonalDataSelection"));
 
 1367                $ilUser->exportPersonalData();
 
 1368                $ilUser->sendPersonalDataFile();
 
 1369                $ilCtrl->redirect($this, 
"showExportImport");
 
 1382                $ilUser->sendPersonalDataFile();
 
 1395                $ilTabs->activateTab(
"export");
 
 1398                $this->initPersonalDataImportForm();
 
 1400                $tpl->setContent($this->form->getHTML());
 
 1414                include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
 
 1419                $fi->setRequired(
true);
 
 1420                $fi->setSuffixes(array(
"zip"));
 
 1421                $this->form->addItem($fi);
 
 1425                $this->form->addItem($cb);
 
 1429                $this->form->addItem($cb);
 
 1433                $this->form->addItem($cb);
 
 1437                $this->form->addItem($cb);
 
 1441                $this->form->addItem($cb);
 
 1443                $this->form->addCommandButton(
"importPersonalData", 
$lng->txt(
"import"));
 
 1444                $this->form->addCommandButton(
"showExportImport", 
$lng->txt(
"cancel"));
 
 1446                $this->form->setTitle(
$lng->txt(
"pd_import_personal_data"));
 
 1447                $this->form->setFormAction(
$ilCtrl->getFormAction($this));
 
 1462                $this->initPersonalDataImportForm();
 
 1463                if ($this->form->checkInput())
 
 1465                        $ilUser->importPersonalData($_FILES[
"file"],
 
 1466                                (
int) 
$_POST[
"profile_data"],
 
 1467                                (
int) 
$_POST[
"settings"],
 
 1468                                (
int) 
$_POST[
"bookmarks"],
 
 1477                        $ilTabs->activateTab(
"export");
 
 1479                        $this->form->setValuesByPost();
 
 1480                        $tpl->setContent($this->form->getHtml());
 
An exception for terminatinating execution or to throw for unit testing.
static getInstancesByUserId($a_user_id)
static updatePositions($a_user_id, array $a_positions)
static getInstance()
Constructor.
static formatDate(ilDateTime $date)
Format a date @access public.
static updateLuceneIndex($a_obj_ids)
Update lucene index.
static isActivated()
Checks whether Map feature is activated.
static getDefaultSettings()
Get default longitude, latitude and zoom.
This class represents a non editable value in a property form.
static getDefaultPortfolio($a_user_id)
Get default portfolio of user.
getLatitude()
Get Latitude.
static _getPersonalPicturePath($a_usr_id, $a_size="small", $a_force_pic=false, $a_prevent_no_photo_image=false)
Get path to personal picture.
getCountry()
Get country (free text)
getLongitude()
Get Longitude.
getLocationZoom()
Get Location Zoom.
getStreet()
get street @access public
getCity()
get city @access public
static _loginExists($a_login, $a_user_id=0)
check if a login name already exists You may exclude a user from the check by giving his user id as 2...
GUI class for personal profile.
saveProfile()
save user profile data
workWithUserSetting($setting)
Returns TRUE if working with the given user setting is allowed, FALSE otherwise.
initPersonalDataImportForm()
Init personal data import form.
showPublicProfileFields(ilPropertyformGUI $form, array $prefs, $parent=null, $anonymized=false)
Add fields to form.
importPersonalData()
Import personal data.
showPersonalData($a_no_init=false)
Personal data form.
showPublicProfile($a_no_init=false)
Public profile form.
executeCommand()
execute command
initPersonalDataForm()
Init personal form.
savePersonalData()
Save personal data form.
savePublicProfile()
Save public profile form.
exportPersonalData()
Export personal data.
userSettingVisible($setting)
Returns TRUE if user setting is visible, FALSE otherwise.
removeUserPicture()
remove user image
__checkUserDefinedRequiredFields()
getProfilePortfolio()
has profile set to a portfolio?
showExportImport()
Show export/import.
__showUserDefinedFields()
uploadUserPicture()
Upload user image.
downloadPersonalData()
Download personal data export file.
userSettingEnabled($setting)
Returns TRUE if user setting is enabled, FALSE otherwise.
__showOtherInformations()
importPersonalDataSelection()
Import personal data selection.
initPublicProfileForm()
Init public profile form.
showProfile()
show profile form
addLocationToForm(ilPropertyFormGUI $a_form, ilObjUser $a_user)
Add location fields to form if activated.
GUI class for public user profile presentation.
This class represents an option in a radio group.
static set($a_var, $a_val)
Set a value.
static get($a_var)
Get a value.
special template class to simplify handling of ITX/PEAR
This class represents a text area property in a property form.
This class represents a text property in a property form.
static _getInstance()
Get instance.
Class for user related exception handling in ILIAS.
static is_email($a_email)
This preg-based function checks whether an e-mail address is formally valid.
static isConvertVersionAtLeast($a_version)
Compare convert version numbers.
static escapeShellArg($a_arg)
static getWebspaceDir($mode="filesystem")
get webspace directory
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static execConvert($args)
execute convert command
static redirect($a_script)
http redirect to other script
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static formSelect($selected, $varname, $options, $multiple=false, $direct_text=false, $size="0", $style_class="", $attribs="", $disabled=false)
Builds a select form field with options and shows the selected option first.
static prepareFormOutput($a_str, $a_strip=false)
prepares string output for html forms @access public
$GLOBALS['loaded']
Global hash that tracks already loaded includes.
redirection script todo: (a better solution should control the processing via a xml file)
if(!is_array($argv)) $options