0) ? (int)$_GET['page'] : 1; $limit_user = (isset($_GET['limit']) && (int)$_GET['limit'] > 0) ? (int)$_GET['limit'] : 10; $search_field = (isset($_GET['search']) && !empty($_GET['search'])) ? $_GET['search'] : false; if(hasValue($loggedInUserInfo) && is_array($loggedInUserInfo) && $loggedInUserInfo["users_page_limit"] && !(isset($_GET['limit']) and !empty($_GET['limit']))){ $limit_user = $loggedInUserInfo["users_page_limit"]; } echo '

'.get_lang('users')."

"; $result = $db->getUserList_limit($page_user, $limit_user, $search_field); if (empty($result) && $search_field !== false) { print_failure(get_lang_f('no_results_found', htmlentities($search_field))); $view->refresh("?m=user_admin", 5); return; } echo '

'.get_lang("add_new_user").'

'; echo ''; echo '"; echo ""; echo ""; echo ""; echo ""; $i = 0; foreach ( $result as $row ) { // Show user's parent $ownedBy = ""; if(!is_null($row['users_parent'])){ $ownedBy = $row['users_parent']; $parentInfo = $db->getUserById($ownedBy); if(is_array($parentInfo) && array_key_exists("user_expires", $parentInfo) && $parentInfo['user_expires'] != "X"){ $row['user_expires'] = $parentInfo['user_expires']; } } $user_expires = read_expire($row['user_expires']); print ""; print ""; if(!empty($ownedBy)){ print ""; }else{ print ""; } print ""; } echo '
'.get_lang('actions')."".get_lang('username')."".get_lang('user_role')."".get_lang('email_address')."".get_lang('expires')."".get_lang('subusers')."
[". get_lang('assign_homes')."]
[".get_lang('delete')."]
[".get_lang('edit_profile')."]
".htmlentities($row['users_login'])."".htmlentities($row['users_role'])." ".htmlentities($row['users_email'])." $user_expires" . get_lang('show_subusers') . " ↓

'; $count_users = $db->get_user_count($search_field); if(isset($_GET['search']) && !empty($_GET['search'])){ $uri = '?m=user_admin&search='.$_GET['search'].'&limit='.$limit_user.'&page='; } else{ $uri = '?m=user_admin&limit='.$limit_user.'&page='; } echo paginationPages($count_users[0]['total'], $page_user, $limit_user, $uri, 3, 'userManager'); } ?>