Hello!
I am customizing my register of users and I saw that the file registerform.php has this code under comments:
//$avatar_select = new XoopsFormSelect("", "user_avatar", $user_avatar);
//$avatar_array =& XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH."/images/avatar/");
//$avatar_select->addOptionArray($avatar_array);
//$a_dirlist =& XoopsLists::getDirListAsArray(XOOPS_ROOT_PATH."/images/avatar/");
//$a_dir_labels = array();
//$a_count = 0;
//$a_dir_link = "
XOOPS";
//$a_count = $a_count + count($avatar_array);
//$a_dir_labels[] = new XoopsFormLabel("", $a_dir_link);
//foreach ($a_dirlist as $a_dir) {
// if ( $a_dir == "users" ) {
// continue;
// }
// $avatars_array =& XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH."/images/avatar/".$a_dir."/", $a_dir."/");
// $avatar_select->addOptionArray($avatars_array);
// $a_dir_link = "
".$a_dir."";
// $a_dir_labels[] = new XoopsFormLabel("", $a_dir_link);
// $a_count = $a_count + count($avatars_array);
//}
//$avatar_select->setExtra("onchange='showImgSelected(\"avatar\", \"user_avatar\", \"images/avatar\", \"\", \"".XOOPS_URL."\")'");
//$avatar_label = new XoopsFormLabel("", "
");
//$avatar_tray = new XoopsFormElementTray(_US_AVATAR, " ");
//$avatar_tray->addElement($avatar_select);
//$avatar_tray->addElement($avatar_label);
//foreach ($a_dir_labels as $a_dir_label) {
// $avatar_tray->addElement($a_dir_label);
//}
What is this for??
I think it is for selecting an avatar when one registers.
But I remove the // and nothing seems to change. Why?
And if this is not for that, how will I be able to do ONE of the following:
1) TO HAVE 2 REGISTER FORMS OR PAGES. One is the neccesary fields to fill to enter the community, and the other is to fill other fields that are not necesary but helpful like avatar, hobbiens, etc.
2) Redirect the user after filling the needed fields to register to the view/edit profile page.
Any ideas? Thanks.
Jordi.