Minahito
minah****@users*****
2006年 1月 19日 (木) 21:12:07 JST
Index: xoops2jp/html/modules/user/class/groups.php diff -u /dev/null xoops2jp/html/modules/user/class/groups.php:1.1.2.1 --- /dev/null Thu Jan 19 21:12:07 2006 +++ xoops2jp/html/modules/user/class/groups.php Thu Jan 19 21:12:07 2006 @@ -0,0 +1,21 @@ +<?php + +class UserGroupsObject extends XoopsSimpleObject +{ + function UserGroupsObject() + { + $this->initVar('groupid', XOBJ_DTYPE_INT, '', true); + $this->initVar('name', XOBJ_DTYPE_STRING, '', true, 50); + $this->initVar('description', XOBJ_DTYPE_TEXT, '', true); + $this->initVar('group_type', XOBJ_DTYPE_STRING, '', true, 10); + } +} + +class UserGroupsHandler extends XoopsObjectGenericHandler +{ + var $mTable = "groups"; + var $mPrimary = "groupid"; + var $mClass = "UserGroupsObject"; +} + +?> Index: xoops2jp/html/modules/user/class/PageNavigator.class.php diff -u /dev/null xoops2jp/html/modules/user/class/PageNavigator.class.php:1.1.2.1 --- /dev/null Thu Jan 19 21:12:07 2006 +++ xoops2jp/html/modules/user/class/PageNavigator.class.php Thu Jan 19 21:12:07 2006 @@ -0,0 +1,35 @@ +<?php + +require_once XOOPS_ROOT_PATH . "/class/XCube_PageNavigator.class.php"; + +class User_PageNavigator extends XCube_PageNavigator +{ + function getRenderSortUrl() + { + return parent::renderSortUrl('sort'); + } + + function renderHidden($sort = null) + { + if ($mask == null) { + $mask = array(); + } + elseif (!is_array($mask)) { + $mask = array($mask); + } + + $ret = null; + + foreach ($this->mExtra as $key => $value) { + } + + if (!isset($mask[$key])) { + $value = htmlspecialchars($value, ENT_QUOTES); + $ret .= "<input type=\"hidden\" name=\"${key}\" value=\"${value}\" />"; + } + + return $ret; + } +} + +?> Index: xoops2jp/html/modules/user/class/avatar.php diff -u /dev/null xoops2jp/html/modules/user/class/avatar.php:1.1.2.1 --- /dev/null Thu Jan 19 21:12:07 2006 +++ xoops2jp/html/modules/user/class/avatar.php Thu Jan 19 21:12:07 2006 @@ -0,0 +1,31 @@ +<?php + +class UserAvatarObject extends XoopsSimpleObject +{ + function UserAvatarObject() + { + $this->initVar('avatar_id', XOBJ_DTYPE_INT, 0, true); + $this->initVar('avatar_file', XOBJ_DTYPE_STRING, '', true, 30); + $this->initVar('avatar_name', XOBJ_DTYPE_STRING, '', true, 100); + $this->initVar('avatar_mimetype', XOBJ_DTYPE_STRING, '', true, 30); + $this->initVar('avatar_created', XOBJ_DTYPE_INT, time(), true); + $this->initVar('avatar_display', XOBJ_DTYPE_BOOL, '0', true); + $this->initVar('avatar_weight', XOBJ_DTYPE_INT, '0', true); + $this->initVar('avatar_type', XOBJ_DTYPE_STRING, 'S', true, 1); + } +} + +class UserAvatarHandler extends XoopsObjectGenericHandler +{ + var $mTable = "avatar"; + var $mPrimary = "avatar_id"; + var $mClass = "UserAvatarObject"; + + function delete(&$obj) + { + @unlink(XOOPS_UPLOAD_PATH . "/" . $obj->get('avatar_name')); + return parent::delete($obj); + } +} + +?>