本文整理汇总了PHP中UserManager::getAllUsers方法的典型用法代码示例。如果您正苦于以下问题:PHP UserManager::getAllUsers方法的具体用法?PHP UserManager::getAllUsers怎么用?PHP UserManager::getAllUsers使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UserManager
的用法示例。
在下文中一共展示了UserManager::getAllUsers方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: UserManager
<!DOCTYPE HTML>
<html>
<head>
<title>TESTING PAGE</title>
</head>
<body>
<?php
// Include utility files
require_once '../config.php';
require_once BUSINESS_DIR_USER . 'UserManager.php';
$userManager = new UserManager();
$Users = $userManager->getAllUsers();
echo "<br/><br/><br/><b>See All Users</b><br>";
$userCount = count($Users);
echo "user count: " . $userCount . ".<br/>";
if ($userCount > 0) {
foreach ($Users as $users) {
$uid = $users->getUserId();
$fname = $users->getFirstName();
$lname = $users->getLastName();
$pwd = $users->getPassword();
$loginid = $users->getLogin();
$email = $users->getEmail();
$dob = $users->getDOB();
$language = $users->getUserLanguage();
$usertype = $users->getUserType();
$regdate = $users->getRegistrationDate();
$location = $users->getLocation();
$mediaid = $users->getMediaId();
$ratingid = $users->getUserRatingId();
示例2: md5
$_code = md5($_email . time());
$_id = UserManager::requireChangePassword($_number, $_email, $_code);
if ($_id != NULL && $_id > 0) {
sendVerifyPwd($_id, $_email, $_code);
}
echo $_id;
break;
case 'EDIT':
$_user = new User(NULL, $_REQUEST['name'], $_REQUEST['avatar'], $_REQUEST['gcmid'], NULL, $_REQUEST['gender'], $_REQUEST['address'], $_REQUEST['birthday'], $_REQUEST['school'], $_REQUEST['workplace'], $_REQUEST['email'], $_REQUEST['fblink'], $_REQUEST['ispublic']);
echo UserManager::editUser($_REQUEST['id'], $_user);
break;
case 'DELETE':
echo UserManager::removeUser($_REQUEST['id']);
break;
case 'GET_USER_LIST':
echo json_encode(array('users' => UserManager::getAllUsers()));
break;
case 'GET_USER_LIST_BY_NAME':
echo json_encode(array('users' => UserManager::getAllUsersByName($_REQUEST['id'], $_REQUEST['name'])));
break;
case 'GET_USER_LIST_BY_ADDRESS':
echo json_encode(array('users' => UserManager::getAllUsersByAddress($_REQUEST['id'], $_REQUEST['address'])));
break;
case 'GET_USER_LIST_BY_SCHOOL':
echo json_encode(array('users' => UserManager::getAllUsersBySchool($_REQUEST['id'], $_REQUEST['school'])));
break;
case 'GET_USER_LIST_BY_WORKPLACE':
echo json_encode(array('users' => UserManager::getAllUsersByWorkplace($_REQUEST['id'], $_REQUEST['workplace'])));
break;
case 'GET_USER_LIST_BY_GENDER':
echo json_encode(array('users' => UserManager::getAllUsersByGender($_REQUEST['id'], $_REQUEST['gender'])));
示例3: foreach
foreach ($_tb as $_row) {
$s .= '<tr>';
$s .= '<td>' . $_row . '</td>';
$s .= '</tr>';
}
$s .= '</table><br />';
echo $s;
}
?>
<?php
switch ($_POST["t"]) {
case "u":
echo "<h1 style='color:#09C'>USER DATA</h1>";
require_once "user.php";
$_hx = array("id", "name", "avatarlink", "gcmid", "lastlogin", "gender", "address", "birthday", "school", "workplace", "email", "fblink", "ispublic");
$_tbx = UserManager::getAllUsers();
show($_hx, $_tbx);
break;
case "a":
echo "<h1 style='color:#09C'>ACCOUNT DATA</h1>";
require_once "account.php";
$_hx = array("number");
$_tbx = AccountManager::getAllAcounts();
show2($_hx, $_tbx);
break;
case "f":
echo "<h1 style='color:#09C'>FRIEND DATA</h1>";
require_once "friend.php";
$_hx = array("uid", "fid", "share");
$_tbx = FriendManager::getAllFriendList();
show($_hx, $_tbx);
示例4: Page
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
include "../core.php";
// Admin Check
$user = UserManager::getLocalUser();
if (!$user->isAdmin()) {
PageManager::displayErrorPage("access");
return;
}
$page = new Page($smarty, "modals/AdminGameserverAdd.tpl");
// Users
$c = UserManager::getAllUsers();
if ($c === false) {
$page->assign("t_Report", Reporting::info("There are no users yet. Try <a href='" . Core::GetConfig("dirRoot") . "Customer'>adding one</a>."));
} else {
$page->assign("customerArrayData", $c);
}
// Templates
$c = TemplateManager::getAllGameserverTemplates();
if ($c == false) {
$page->assign("t_Report", Reporting::info("There are no not gameserver templates yet. Try <a href='" . Core::GetConfig("dirRoot") . "Templates'>adding one</a>."));
} else {
$page->assign("templateArrayData", $c);
}
// Physical Servers
$c = PhysicalServerManager::getAllPhysicalServer();
if ($c === false) {
示例5: GeneralView
<?php
require_once "views/GeneralView.class.php";
require_once "views/ErrorOrSuccessView.class.php";
require_once "private/config.php";
require_once "models/Agenda.class.php";
require_once "models/AgendaManager.class.php";
require_once "models/User.class.php";
require_once "models/UserManager.class.php";
require_once "models/Commentaire.class.php";
require_once "models/CommentaireManager.class.php";
$viewG = new GeneralView();
$manager = new AgendaManager($db);
$userMan = new UserManager($db);
$commentMan = new CommentaireManager($db);
$viewG->header("CalendarFactory");
$viewG->navBar("Admin");
$dataTabAgenda = $manager->getAllAllAgenda();
$dataTabUser = $userMan->getAllUsers();
$dataTabComm = $commentMan->getAllComments();
$viewG->generateAdminPanel($dataTabUser, $dataTabAgenda, $dataTabComm);
$viewG->footer();
示例6: sizeof
<?php
require_once '../user.php';
$resultUsers = UserManager::getAllUsers();
if ($resultUsers != false) {
$NumOfUsers = sizeof($resultUsers);
} else {
$NumOfUsers = 0;
}
// var_dump($resultUsers);
?>
<!DOCTYPE html>
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
});
function sendPushNotification(id){
var data = $('form#'+id).serialize();
$('form#'+id).unbind('submit');
$.ajax({
url: "send_push_notification_message.php",
type: 'GET',
data: data,
beforeSend: function() {