• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP UserList类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中UserList的典型用法代码示例。如果您正苦于以下问题:PHP UserList类的具体用法?PHP UserList怎么用?PHP UserList使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了UserList类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: wp_getauthors

/**
 * wp.getAuthors
 *
 * @see http://codex.wordpress.org/XML-RPC_wp#wp.getAuthors
 *
 * @param xmlrpcmsg XML-RPC Message
 *					0 blogid (int): Unique identifier of the blog.
 *					1 username (string): User login.
 *					2 password (string): Password for said username.
 */
function wp_getauthors($m)
{
    // CHECK LOGIN:
    /**
     * @var User
     */
    if (!($current_User =& xmlrpcs_login($m, 1, 2))) {
        // Login failed, return (last) error:
        return xmlrpcs_resperror();
    }
    // GET BLOG:
    /**
     * @var Blog
     */
    if (!($Blog =& xmlrpcs_get_Blog($m, 0))) {
        // Login failed, return (last) error:
        return xmlrpcs_resperror();
    }
    if (!$current_User->check_perm('users', 'view')) {
        return xmlrpcs_resperror(5, T_('You have no permission to view other users!'));
    }
    load_class('users/model/_userlist.class.php', 'UserList');
    $UserList = new UserList('', NULL, 'u_', array('join_group' => false, 'join_session' => false, 'join_country' => false, 'join_city' => false));
    // Run the query:
    $UserList->query();
    logIO('Found users: ' . $UserList->result_num_rows);
    $data = array();
    while ($User =& $UserList->get_next()) {
        $data[] = new xmlrpcval(array('user_id' => new xmlrpcval($User->ID, 'int'), 'user_login' => new xmlrpcval($User->login), 'display_name' => new xmlrpcval($User->get_preferred_name())), 'struct');
    }
    logIO('OK.');
    return new xmlrpcresp(new xmlrpcval($data, 'array'));
}
开发者ID:ldanielz,项目名称:uesp.blog,代码行数:43,代码来源:_wordpress.api.php


示例2: __construct

 /**
  * Constructor.
  *
  * @access  public
  * @param   UserList   $list        User List Object.
  * @param   User       $user        User object owning tag/note metadata.
  * @param   int        $listId      ID of list containing desired tags/notes (or
  *                                  null to show tags/notes from all user's lists).
  * @param   bool       $allowEdit   Should we display edit controls?
  */
 public function __construct($list, $user, $allowEdit = true)
 {
     $this->list = $list;
     $this->user = $user;
     $this->listId = $list->id;
     $this->allowEdit = $allowEdit;
     // Determine Sorting Option //
     if (isset($list->defaultSort)) {
         $this->defaultSort = $list->defaultSort;
     }
     // when list as a sort setting use that
     if (isset($_REQUEST['sort']) && (in_array($_REQUEST['sort'], $this->solrSortOptions) || in_array($_REQUEST['sort'], array_keys($this->userListSortOptions)))) {
         // if URL variable is a valid sort option, set the list's sort setting
         $this->sort = $_REQUEST['sort'];
     } else {
         $this->sort = $this->defaultSort;
     }
     $this->isUserListSort = in_array($this->sort, array_keys($this->userListSortOptions));
     // Get the Favorites //
     $userListSort = $this->isUserListSort ? $this->userListSortOptions[$this->sort] : null;
     $this->favorites = $list->getListEntries($userListSort);
     // when using a user list sorting, rather than solr sorting, get results in order
     // Process the IDs found in the favorites
     foreach ($this->favorites as $favorite) {
         if (is_object($favorite)) {
             $this->ids[] = $favorite->groupedWorkPermanentId;
         } else {
             $this->ids[] = $favorite;
         }
     }
 }
开发者ID:victorfcm,项目名称:VuFind-Plus,代码行数:41,代码来源:FavoriteHandler.php


示例3: createuser

 public function createuser()
 {
     $errmsg = array();
     if ($this->registry->auth->check()) {
         header("Location: /store");
         return;
     }
     if (false == preg_match('/^[a-zA-Z0-9_]+$/', $this->registry->request->login)) {
         $errmsg[] = 'Login should consist from alphanumeric characters';
     }
     if (false == preg_match('/^[a-zA-Z0-9_]+$/', $this->registry->request->pass)) {
         $errmsg[] = 'Password should consist from alphanumeric characters';
     }
     if ($this->registry->request->pass !== $this->registry->request->pass_confirm) {
         $errmsg[] = 'Wrong password confirmation';
     }
     /** Instance of UserList class, lib/userlist.class.php */
     $ul = new UserList();
     /** Check if user exists */
     if ($ul->isRegistered($this->registry->request->login)) {
         $errmsg[] = 'This username is unavailable.';
     }
     /** Create new user */
     if (false == $ul->createUser($this->registry->request->login, $this->registry->request->pass)) {
         $errmsg[] = 'Fatal error. Try again later.';
     }
     if (count($errmsg) > 0) {
         $this->registry->view->errormessages = $errmsg;
         $this->registry->view->render('register');
         return;
     }
     unset($ul);
     $this->registry->view->render('register_ok');
 }
开发者ID:re-lre-l,项目名称:eshop-mvc,代码行数:34,代码来源:registerController.class.php


示例4: signin

 public function signin()
 {
     $errmsg = array();
     if ($this->registry->auth->check()) {
         header("Location: /store");
         return;
     }
     if (false == preg_match('/^[a-zA-Z0-9_]+$/', $this->registry->request->login)) {
         $errmsg[] = 'Login should consist from alphanumeric characters';
     }
     if (false == preg_match('/^[a-zA-Z0-9_]+$/', $this->registry->request->pass)) {
         $errmsg[] = 'Password should consist from alphanumeric characters';
     }
     /** instance of UserList class, lib/userlist.class.php */
     $ul = new UserList();
     if (!($passwordHash = $ul->isRegistered($this->registry->request->login))) {
         $errmsg[] = 'Wrong login.';
     }
     if (md5($this->registry->request->pass) !== $passwordHash) {
         $errmsg[] = 'Wrong password.';
     }
     if (count($errmsg) > 0) {
         $this->registry->view->errormessages = $errmsg;
         $this->registry->view->render('login');
         return;
     }
     unset($ul);
     $this->registry->auth->login();
     $this->registry->view->username = $this->registry->request->login;
     $this->registry->view->render('login_ok');
 }
开发者ID:re-lre-l,项目名称:eshop-mvc,代码行数:31,代码来源:loginController.class.php


示例5: getRequestedSearchResults

 public function getRequestedSearchResults()
 {
     $userList = new UserList();
     $userList->sortBy('uDateAdded', 'desc');
     $userList->showInactiveUsers = true;
     $userList->showInvalidatedUsers = true;
     if ($_GET['keywords'] != '') {
         $userList->filterByKeywords($_GET['keywords']);
     }
     if ($_REQUEST['numResults']) {
         $userList->setItemsPerPage($_REQUEST['numResults']);
     }
     if (isset($_REQUEST['gID']) && is_array($_REQUEST['gID'])) {
         foreach ($_REQUEST['gID'] as $gID) {
             $userList->filterByGroupID($gID);
         }
     }
     if (is_array($_REQUEST['selectedSearchField'])) {
         foreach ($_REQUEST['selectedSearchField'] as $i => $item) {
             // due to the way the form is setup, index will always be one more than the arrays
             if ($item != '') {
                 switch ($item) {
                     case 'is_active':
                         if ($_GET['active'] === '0') {
                             $userList->filterByIsActive(0);
                         } else {
                             if ($_GET['active'] === '1') {
                                 $userList->filterByIsActive(1);
                             }
                         }
                         break;
                     case "date_added":
                         $dateFrom = $_REQUEST['date_from'];
                         $dateTo = $_REQUEST['date_to'];
                         if ($dateFrom != '') {
                             $dateFrom = date('Y-m-d', strtotime($dateFrom));
                             $userList->filterByDateAdded($dateFrom, '>=');
                             $dateFrom .= ' 00:00:00';
                         }
                         if ($dateTo != '') {
                             $dateTo = date('Y-m-d', strtotime($dateTo));
                             $dateTo .= ' 23:59:59';
                             $userList->filterByDateAdded($dateTo, '<=');
                         }
                         break;
                     default:
                         $akID = $item;
                         $fak = UserAttributeKey::get($akID);
                         $type = $fak->getAttributeType();
                         $cnt = $type->getController();
                         $cnt->setAttributeKey($fak);
                         $cnt->searchForm($userList);
                         break;
                 }
             }
         }
     }
     return $userList;
 }
开发者ID:VonUniGE,项目名称:concrete5-1,代码行数:59,代码来源:search.php


示例6: getAccessEntityUsers

 public function getAccessEntityUsers(PermissionAccess $pa)
 {
     $gl = new UserList();
     foreach ($this->groups as $g) {
         $gl->filterByGroupID($g->getGroupID());
     }
     return $gl->get();
 }
开发者ID:Zyqsempai,项目名称:amanet,代码行数:8,代码来源:group_combination.php


示例7: get_filterset_user_IDs

/**
 * Get user IDs from current filterset of users list
 *
 * @param string Filterset name
 * return array User IDs
 */
function get_filterset_user_IDs($filterset_name = 'admin')
{
    load_class('users/model/_userlist.class.php', 'UserList');
    // Initialize users list from session cache in order to get users IDs for newsletter
    $UserList = new UserList($filterset_name);
    $UserList->memorize = false;
    $UserList->load_from_Request();
    return $UserList->filters['users'];
}
开发者ID:Ariflaw,项目名称:b2evolution,代码行数:15,代码来源:_emailcampaign.funcs.php


示例8: view

	public function view() {
		$userList = new UserList(); 
		$userList->sortBy('uName', 'asc'); 
		$keywords = $this->get('keywords');
		if ($keywords != '') {
			$userList->filterByKeywords($keywords);
		}
		$users = $userList->getPage();
		$this->set('userList', $userList);						
		$this->set('users', $users);
		$this->set('attribs', UserAttributeKey::getMemberListList());
		$this->set('keywords', htmlentities($keywords, ENT_COMPAT, APP_CHARSET));
		$this->addHeaderItem(Loader::helper('html')->css('ccm.profile.css'));
	}
开发者ID:rii-J,项目名称:concrete5-de,代码行数:14,代码来源:members.php


示例9: __construct

 public function __construct($seedUserListId = null, $seedUserListName = null, $seedUserListDescription = null, $seedUserListStatus = null, $seedListSize = null, $id = null, $isReadOnly = null, $name = null, $description = null, $status = null, $integrationCode = null, $accessReason = null, $accountUserListStatus = null, $membershipLifeSpan = null, $size = null, $sizeRange = null, $sizeForSearch = null, $sizeRangeForSearch = null, $listType = null, $isEligibleForSearch = null, $isEligibleForDisplay = null, $UserListType = null)
 {
     parent::__construct();
     $this->seedUserListId = $seedUserListId;
     $this->seedUserListName = $seedUserListName;
     $this->seedUserListDescription = $seedUserListDescription;
     $this->seedUserListStatus = $seedUserListStatus;
     $this->seedListSize = $seedListSize;
     $this->id = $id;
     $this->isReadOnly = $isReadOnly;
     $this->name = $name;
     $this->description = $description;
     $this->status = $status;
     $this->integrationCode = $integrationCode;
     $this->accessReason = $accessReason;
     $this->accountUserListStatus = $accountUserListStatus;
     $this->membershipLifeSpan = $membershipLifeSpan;
     $this->size = $size;
     $this->sizeRange = $sizeRange;
     $this->sizeForSearch = $sizeForSearch;
     $this->sizeRangeForSearch = $sizeRangeForSearch;
     $this->listType = $listType;
     $this->isEligibleForSearch = $isEligibleForSearch;
     $this->isEligibleForDisplay = $isEligibleForDisplay;
     $this->UserListType = $UserListType;
 }
开发者ID:sonicgd,项目名称:google-adwords-api-light,代码行数:26,代码来源:SimilarUserList.php


示例10: launch

 function launch()
 {
     global $interface;
     //Get all lists for the user
     // Fetch List object
     if (isset($_REQUEST['id'])) {
         /** @var UserList $list */
         $list = UserList::staticGet($_GET['listId']);
     }
     $interface->assign('favList', $list);
     // Get all titles on the list
     //		$favorites = $list->getListEntries();
     //		$favList = new FavoriteHandler($favorites, null, $list->id, false);
     //TODO: test this
     $favList = new FavoriteHandler($list, null, false);
     $citationFormat = $_REQUEST['citationFormat'];
     $citationFormats = CitationBuilder::getCitationFormats();
     $interface->assign('citationFormat', $citationFormats[$citationFormat]);
     $citations = $favList->getCitations($citationFormat);
     $interface->assign('citations', $citations);
     // Display Page
     $interface->assign('listId', strip_tags($_REQUEST['id']));
     $interface->setTemplate('listCitations.tpl');
     $interface->display('layout.tpl');
 }
开发者ID:victorfcm,项目名称:VuFind-Plus,代码行数:25,代码来源:CiteList.php


示例11: launch

 function launch($msg = null)
 {
     global $interface;
     global $configArray;
     if (!($user = UserAccount::isLoggedIn())) {
         require_once ROOT_DIR . '/services/MyAccount/Login.php';
         MyAccount_Login::launch();
         exit;
     }
     // Save Data
     if (isset($_POST['submit'])) {
         $this->saveChanges($user);
         // After changes are saved, send the user back to an appropriate page;
         // either the list they were viewing when they started editing, or the
         // overall favorites list.
         if (isset($_REQUEST['list_id'])) {
             $nextAction = 'MyList/' . $_REQUEST['list_id'];
         } else {
             $nextAction = 'Home';
         }
         header('Location: ' . $configArray['Site']['path'] . '/MyAccount/' . $nextAction);
         exit;
     }
     require_once ROOT_DIR . '/sys/LocalEnrichment/UserList.php';
     $userList = new UserList();
     $userList->id = $_REQUEST['list_id'];
     $userList->find(true);
     $interface->assign('list', $userList);
     require_once ROOT_DIR . '/RecordDrivers/GroupedWorkDriver.php';
     $id = $_GET['id'];
     $groupedWorkDriver = new GroupedWorkDriver($id);
     if ($groupedWorkDriver->isValid) {
         $interface->assign('recordDriver', $groupedWorkDriver);
     }
     // Record ID
     $interface->assign('recordId', $id);
     // Retrieve saved information about record
     require_once ROOT_DIR . '/sys/LocalEnrichment/UserListEntry.php';
     $userListEntry = new UserListEntry();
     $userListEntry->groupedWorkPermanentId = $id;
     $userListEntry->listId = $_REQUEST['list_id'];
     $userListEntry->find(true);
     $interface->assign('listEntry', $userListEntry);
     $interface->assign('listFilter', $_GET['list_id']);
     $interface->setTemplate('editListTitle.tpl');
     $interface->display('layout.tpl');
 }
开发者ID:victorfcm,项目名称:VuFind-Plus,代码行数:47,代码来源:Edit.php


示例12: handleSearch

 function handleSearch($p)
 {
     $list = UserList::getUsers($p['q']);
     echo '<h2>Showing users matching <u>' . $p['q'] . '</u>';
     echo ' (' . count($list) . ' hits)</h2>';
     $dt = new YuiDatatable();
     $dt->addColumn('id', 'Username', 'link', 'u/profile/', 'name');
     $dt->addColumn('time_last_active', 'Last active');
     $dt->setDataSource($list);
     echo $dt->render();
 }
开发者ID:martinlindhe,项目名称:core_dev,代码行数:11,代码来源:search.php


示例13: getLeaders

 public function getLeaders($searchString, $city, $limit)
 {
     Loader::model('user_list');
     $av = Loader::helper('concrete/avatar');
     $ul = new UserList();
     $ul->filterByKeywords($searchString);
     $ul->filterByGroup('Walk Leaders');
     $ul->filterByIsActive(1);
     $ul->filterByFirstName(null, '!=');
     $ul->filterByFirstName('', '!=');
     $ul->filter('uLastLogin', 0, '!=');
     $ul->sortBy('uLastLogin');
     $userSet = [];
     foreach ($ul->get($limit ?: 5) as $user) {
         $home_city = $user->getAttribute('home_city');
         $userSet[$user->getUserID()] = ['user_id' => $user->getUserID(), 'first_name' => $user->getAttribute('first_name'), 'last_name' => $user->getAttribute('last_name'), 'city_name' => $home_city ? $home_city->getCollectionName() : null, 'city_id' => $home_city ? $home_city->getCollectionID() : null, 'bio' => $user->getAttribute('bio'), 'twitter' => $user->getAttribute('twitter'), 'facebook' => $user->getAttribute('facebook'), 'website' => $user->getAttribute('website'), 'avatar' => $av->getImagePath($user)];
     }
     return json_encode($userSet);
 }
开发者ID:r-bansal,项目名称:janeswalk-web-1,代码行数:19,代码来源:walk_leaders.php


示例14: actionIndex

 public function actionIndex()
 {
     $taxModel = LbTax::model()->getTaxes();
     $list = UserList::model()->getList();
     $translate = Translate::model()->search();
     $translate = new Translate('search');
     $translate->unsetAttributes();
     // clear any default values
     if (isset($_GET['Translate'])) {
         $translate->attributes = $_GET['Translate'];
     }
     LBApplication::render($this, 'index', array('taxModel' => $taxModel, 'list' => $list, 'translate' => $translate));
     //		$this->render('index');
 }
开发者ID:nhuhtlb,项目名称:linxbooks,代码行数:14,代码来源:DefaultController.php


示例15: widget

 /**
  * Echo widget content = list of blog users.
  */
 function widget($args, $instance)
 {
     require_once 'UserList.class.php';
     // parse hidden users string
     if (!empty($instance['hiddenusers'])) {
         $hiddenusers = explode(',', $instance['hiddenusers']);
         $hiddenusers = array_map('trim', $hiddenusers);
     } else {
         $hiddenusers = array();
     }
     $userlist = new UserList();
     $userlist->roles = $instance['roles'];
     $userlist->blogs = $instance['blogs'];
     $userlist->group_by = $instance['group_by'];
     $userlist->hiddenusers = $hiddenusers;
     if (is_array($instance['display'])) {
         $userlist->show_name = in_array('show_name', $instance['display']);
         $userlist->show_postcount = in_array('show_postcount', $instance['display']);
         $userlist->show_bbpress_post_count = in_array('show_bbpress_post_count', $instance['display']);
         $userlist->show_biography = in_array('show_biography', $instance['display']);
         $userlist->user_link = $instance['display']['user_link'];
         $userlist->avatar_size = $instance['display']['avatar_size'];
         $userlist->limit = $instance['display']['limit'];
         $userlist->min_post_count = $instance['display']['min_post_count'];
         $userlist->order = $instance['display']['order'];
         $userlist->sort_direction = $instance['display']['sort_direction'];
     }
     // extract widget arguments
     extract($args, EXTR_SKIP);
     // add the standard title filter
     $title = empty($instance['title']) ? '' : apply_filters('widget_title', $instance['title']);
     // build the widget html
     echo $before_widget;
     echo $before_title . $title . $after_title;
     $userlist->output();
     echo $after_widget;
 }
开发者ID:minorbug,项目名称:wp-author-avatars,代码行数:40,代码来源:AuthorAvatarsWidget.class.php


示例16: addList

 function addList()
 {
     if ($this->user) {
         if (strlen(trim($_REQUEST['title'])) == 0) {
             return new PEAR_Error('list_edit_name_required');
         }
         $list = new UserList();
         $list->title = $_REQUEST['title'];
         $list->description = $_REQUEST['desc'];
         $list->public = $_REQUEST['public'];
         $list->user_id = $this->user->id;
         $list->insert();
         $list->find();
         return $list->id;
     } else {
         return false;
     }
 }
开发者ID:victorfcm,项目名称:VuFind-Plus,代码行数:18,代码来源:ListEdit.php


示例17: run

 public function run()
 {
     //We check the level of the user before to allow him to see the content
     if (isset($this->model->idCategory) && isset($this->filterLevel) && $this->model->idCategory != '') {
         $levelCategory = Category::model()->findByPk($this->model->idCategory);
         if ($levelCategory->level > $this->filterLevel) {
             Yii::app()->user->setFlash('forbiddenLevel', 'Sorry, to have access to this category you need to register a coin which belongs to this category.');
         }
     }
     //If the user makes a research by username, we shouldn't display the anonymous ones
     if (isset($this->model->username) && $this->model->username !== '') {
         $this->model->anonymous = 0;
     }
     //We get the generated criterias
     $criteria = $this->model->getCriteria();
     //We set up the number of Truth we want to display if necessary
     if (isset($this->model->limit)) {
         $criteria->limit = $this->model->limit;
     }
     //We choose the order of display
     $criteria->order = isset($this->model->order) && $this->model->order !== '' ? $this->model->order . " DESC " : " t.voteUp - t.voteDown DESC ";
     //Page manager
     $count = Truth::model()->levelFilter($this->filterLevel)->count($criteria);
     //Use the $this->limit in Pagination otherwise $pages->pageSize to $criteria overriding the $criteria->limit
     $pages = new CPagination(isset($this->model->limit) ? $this->model->limit : $count);
     $pages->pageSize = isset($this->model->limit) ? $this->model->limit : $this->itemsPerPage;
     $pages->applyLimit($criteria);
     //Get the datas
     $datas = Truth::model()->levelFilter($this->filterLevel)->findAll($criteria);
     //Manage favourites
     $modelUserList = new UserList();
     $userLists = CHtml::listData(array(), 'idUserList', 'name');
     if (!Yii::app()->user->isGuest) {
         $userLists = UserList::model()->findAllByAttributes(array('idUser' => Yii::app()->user->getId()));
         $userLists = CHtml::listData($userLists, 'idUserList', 'name');
     }
     //Manage send Challenges
     $friends = CHtml::listData(array(), 'idUser', 'username');
     if (!Yii::app()->user->isGuest) {
         $friends = CHtml::listData(Friend::getFriends(Yii::app()->user->getId()), 'idUser', 'username');
     }
     $this->render('truthList', array('datas' => $datas, 'pages' => $pages, 'userLists' => $userLists, 'friends' => $friends));
 }
开发者ID:rikohz,项目名称:Project1,代码行数:43,代码来源:TruthList.php


示例18: __construct

 public function __construct($conversionTypes = null, $id = null, $isReadOnly = null, $name = null, $description = null, $status = null, $integrationCode = null, $accessReason = null, $accountUserListStatus = null, $membershipLifeSpan = null, $size = null, $sizeRange = null, $sizeForSearch = null, $sizeRangeForSearch = null, $type = null, $UserListType = null)
 {
     parent::__construct();
     $this->conversionTypes = $conversionTypes;
     $this->id = $id;
     $this->isReadOnly = $isReadOnly;
     $this->name = $name;
     $this->description = $description;
     $this->status = $status;
     $this->integrationCode = $integrationCode;
     $this->accessReason = $accessReason;
     $this->accountUserListStatus = $accountUserListStatus;
     $this->membershipLifeSpan = $membershipLifeSpan;
     $this->size = $size;
     $this->sizeRange = $sizeRange;
     $this->sizeForSearch = $sizeForSearch;
     $this->sizeRangeForSearch = $sizeRangeForSearch;
     $this->type = $type;
     $this->UserListType = $UserListType;
 }
开发者ID:anton-github,项目名称:google-adwords-api-light,代码行数:20,代码来源:BasicUserList.php


示例19: launch

 /**
  * Process parameters and display the page.
  *
  * @return void
  * @access public
  */
 public function launch()
 {
     global $interface;
     global $configArray;
     if (!($user = UserAccount::isLoggedIn())) {
         include_once 'Login.php';
         MyAccount_Login::launch();
         exit;
     }
     // Fetch List object
     $list = UserList::staticGet($_GET['id']);
     // Ensure user have privs to view the list
     if ($list->user_id != $user->id) {
         PEAR_Singleton::raiseError(new PEAR_Error(translate('list_access_denied')));
     }
     // Save Data
     if (isset($_POST['submit'])) {
         if (empty($_POST['title'])) {
             $interface->assign('errorMsg', 'list_edit_name_required');
         } else {
             if ($this->_saveChanges($user, $list)) {
                 // After changes are saved, send the user back to an appropriate page
                 $nextAction = 'MyList/' . $list->id;
                 header('Location: ' . $configArray['Site']['path'] . '/MyResearch/' . $nextAction);
                 exit;
             } else {
                 // List was not edited
                 $interface->assign('errorMsg', 'edit_list_fail');
             }
         }
     }
     // Send list to template so title/description can be displayed:
     $interface->assign('list', $list);
     $interface->setTemplate('editList.tpl');
     $interface->display('layout.tpl');
 }
开发者ID:victorfcm,项目名称:VuFind-Plus,代码行数:42,代码来源:EditList.php


示例20: load_funcs

     $admin_Plugins->restart();
     $edit_Plugin =& $admin_Plugins->get_by_ID($plugin_ID);
     load_funcs('plugins/_plugin.funcs.php');
     _set_setting_by_path($edit_Plugin, 'UserSettings', $set_path, array());
     $edit_Plugin->Settings->dbupdate();
     $action = 'edit';
     break;
 case 'search':
     // Quick search
     // Check that this action request is not a CSRF hacked request:
     $Session->assert_received_crumb('user');
     param('user_search', 'string', '');
     set_param('keywords', $user_search);
     set_param('filter', 'new');
     load_class('users/model/_userlist.class.php', 'UserList');
     $UserList = new UserList('admin', $UserSettings->get('results_per_page'), 'users_', array('join_city' => false));
     $UserList->load_from_Request();
     // Make query to get a count of users
     $UserList->query();
     if ($UserList->get_total_rows() == 1) {
         // If we find only one user by quick search we do a redirect to user's edit page
         $User = $UserList->rows[0];
         if (!empty($User)) {
             header_redirect('?ctrl=user&user_tab=profile&user_ID=' . $User->user_ID);
         }
     }
     // Unset the filter to avoid the step 1 in the function $UserList->query() on the users list
     set_param('filter', '');
     break;
 case 'remove_sender_customization':
     // Check that this action request is not a CSRF hacked request:
开发者ID:Ariflaw,项目名称:b2evolution,代码行数:31,代码来源:users.ctrl.php



注:本文中的UserList类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP UserListFactory类代码示例发布时间:2022-05-23
下一篇:
PHP UserInfo类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap