本文整理汇总了PHP中group::get_user_groups方法的典型用法代码示例。如果您正苦于以下问题:PHP group::get_user_groups方法的具体用法?PHP group::get_user_groups怎么用?PHP group::get_user_groups使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类group
的用法示例。
在下文中一共展示了group::get_user_groups方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: CNPagination
function generate_inner_html()
{
$CNPagination = new CNPagination();
$group = new group();
$user_group_ids = array();
if ($_SESSION['user']['id']) {
$user_group_ids = $group->get_user_groups($_SESSION['user']['id']);
$user_group_ids = $this->get_user_group_id($user_group_ids);
}
$CNPagination->setPaging($this->Paging);
$this->page_first = $CNPagination->getFirstPage();
$this->page_last = $CNPagination->getLastPage();
$this->page_links = $CNPagination->getPageLinks();
$inner_template = NULL;
switch ($this->mode) {
default:
$inner_template = PA::$blockmodule_path . '/' . get_class($this) . '/cnmodule_content.php';
}
$inner_html_gen = new Template($inner_template);
$this->links = objtoarray($this->links);
$inner_html_gen->set('title', NULL);
// $this->title
$inner_html_gen->set('links', $this->links);
$inner_html_gen->set('total', $this->total);
$inner_html_gen->set('search_str', get_groups_search_options());
$inner_html_gen->set('user_group_ids', $user_group_ids);
$inner_html_gen->set('current_theme_path', PA::$theme_url);
$inner_html_gen->set('page_first', $this->page_first);
$inner_html_gen->set('page_last', $this->page_last);
$inner_html_gen->set('page_links', $this->page_links);
$inner_html = $inner_html_gen->fetch();
return $inner_html;
}
示例2: Pagination
function generate_inner_html()
{
global $current_theme_path, $base_url, $current_blockmodule_path;
$Pagination = new Pagination();
$group = new group();
$user_group_ids = array();
if (@$_SESSION['user']['id']) {
$user_group_ids = $group->get_user_groups($_SESSION['user']['id']);
$user_group_ids = $this->get_user_group_id($user_group_ids);
}
$Pagination->setPaging($this->Paging);
$this->page_first = $Pagination->getFirstPage();
$this->page_last = $Pagination->getLastPage();
$this->page_links = $Pagination->getPageLinks();
$inner_template = NULL;
switch ($this->mode) {
default:
$inner_template = dirname(__FILE__) . '/center_inner_public.tpl';
}
$inner_html_gen =& new Template($inner_template);
$this->links = objtoarray($this->links);
$inner_html_gen->set('links', $this->links);
$inner_html_gen->set('total', $this->total);
$inner_html_gen->set('search_str', get_groups_search_options());
$inner_html_gen->set('user_group_ids', $user_group_ids);
$inner_html_gen->set('current_theme_path', $current_theme_path);
$inner_html_gen->set('base_url', $base_url);
$inner_html_gen->set('page_first', $this->page_first);
$inner_html_gen->set('page_last', $this->page_last);
$inner_html_gen->set('page_links', $this->page_links);
$inner_html = $inner_html_gen->fetch();
return $inner_html;
}