bp_nouveau_pagination (字符串美元的地位

分页for循环

描述

参数

美元的地位

字符串(必需)

文件:bp-templates / bp-nouveau /包括/ template-tags.php

函数bp_nouveau_pagination($position) {$screen = 'dir';$ pagination_type = bp_current_component ();If (bp_is_user()) {$screen = '用户';} elseif (bp_is_group()) {$screen = '组';$ pagination_type = bp_current_action ();If (bp_is_group_admin_page()) {$pagination_type = bp_action_variable(0);}} if ('subgroups' === $pagination_type) {$pagination_type = 'groups';} switch ($pagination_type) {case 'blogs': $pag_count = bp_get_blogs_pagination_count();$ pag_links = bp_get_blogs_pagination_links ();美元top_hook =“bp_before_directory_blogs_list”; $bottom_hook = 'bp_after_directory_blogs_list'; $page_arg = $GLOBALS['blogs_template']->pag_arg; break; case 'members': case 'friends': case 'manage-members': $pag_count = bp_get_members_pagination_count(); $pag_links = bp_get_members_pagination_links(); // Groups single items are not using these hooks if ( ! bp_is_group() ) { $top_hook = 'bp_before_directory_members_list'; $bottom_hook = 'bp_after_directory_members_list'; } $page_arg = $GLOBALS['members_template']->pag_arg; break; case 'groups': $pag_count = bp_get_groups_pagination_count(); $pag_links = bp_get_groups_pagination_links(); $top_hook = 'bp_before_directory_groups_list'; $bottom_hook = 'bp_after_directory_groups_list'; $page_arg = $GLOBALS['groups_template']->pag_arg; break; case 'notifications': $pag_count = bp_get_notifications_pagination_count(); $pag_links = bp_get_notifications_pagination_links(); $top_hook = ''; $bottom_hook = ''; $page_arg = buddypress()->notifications->query_loop->pag_arg; break; case 'membership-requests': $pag_count = bp_get_group_requests_pagination_count(); $pag_links = bp_get_group_requests_pagination_links(); $top_hook = ''; $bottom_hook = ''; $page_arg = $GLOBALS['requests_template']->pag_arg; break; } $count_class = sprintf( '%1$s-%2$s-count-%3$s', $pagination_type, $screen, $position ); $links_class = sprintf( '%1$s-%2$s-links-%3$s', $pagination_type, $screen, $position ); ?>  

更新日志

更新日志
版本 描述
BuddyPress 3.0.0 介绍了。

问题吗?

我们总是很乐意帮助您解决代码或其他问题!搜索我们的开发人员文档联络支持,或与我们联系销售团队