29 $avatar_handler =
$helper->getHandlerAvatar();
33 $this->
setExtra(
'enctype="multipart/form-data"');
36 $avatar_list = $avatar_handler->getListByType(
'S',
true);
37 $avatar_selected =
$xoops->user->getVar(
"user_avatar",
"E");
38 $avatar_selected = in_array($avatar_selected, array_keys($avatar_list)) ? $avatar_selected :
"blank.gif";
39 $avatar_select->addOptionArray($avatar_list);
42 $avatar_select->setExtra(
"onchange='showImgSelected(\"avatar\", \"user_avatar\", \"uploads\", \"\", \"" .
$xoops_url .
"\")'");
44 $avatar_tray->addElement($avatar_select);
45 $avatar_tray->addElement(
new Xoops\Form\Label(
'',
"<a href=\"javascript:openWithSelfMain('" .
$xoops_url .
"/modules/avatars/popup.php','avatars',600,400);\">" .
XoopsLocale::LIST_.
"</a><br />"));
46 $avatar_tray->addElement(
new Xoops\Form\Label(
'',
"<br /><img src='" .
$xoops_upload_url .
"/" . $avatar_selected .
"' name='avatar' id='avatar' alt='' />"));
47 if (
$helper->getConfig(
'avatars_allowupload') == 1 &&
$xoops->user->getVar(
'posts') >=
$helper->getConfig(
'avatars_postsrequired')) {
50 $avatar_tray->addElement($fileseltray_img);
getVar($key, $format= 's')