当前位置: 首页>>代码示例>>PHP>>正文


PHP bp_group_member_demote_link函数代码示例

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


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

示例1: bp_group_mod_memberlist

function bp_group_mod_memberlist($admin_list = false, $group = false)
{
    global $groups_template;
    if (empty($group)) {
        $group =& $groups_template->group;
    }
    if ($group_mods = groups_get_group_mods($group->id)) {
        ?>

		<ul id="mods-list" class="item-list<?php 
        if ($admin_list) {
            ?>
 single-line<?php 
        }
        ?>
">

		<?php 
        foreach ((array) $group_mods as $mod) {
            ?>

			<?php 
            if (!empty($admin_list)) {
                ?>

			<li>

				<?php 
                echo bp_core_fetch_avatar(array('item_id' => $mod->user_id, 'type' => 'thumb', 'width' => 30, 'height' => 30, 'alt' => sprintf(__('Profile picture of %s', 'buddypress'), bp_core_get_user_displayname($mod->user_id))));
                ?>

				<h5>
					<?php 
                echo bp_core_get_userlink($mod->user_id);
                ?>

					<span class="small">
						<a href="<?php 
                bp_group_member_promote_admin_link(array('user_id' => $mod->user_id));
                ?>
" class="button confirm mod-promote-to-admin" title="<?php 
                esc_attr_e('Promote to Admin', 'buddypress');
                ?>
"><?php 
                _e('Promote to Admin', 'buddypress');
                ?>
</a>
						<a class="button confirm mod-demote-to-member" href="<?php 
                bp_group_member_demote_link($mod->user_id);
                ?>
"><?php 
                _e('Demote to Member', 'buddypress');
                ?>
</a>
					</span>
				</h5>
			</li>

			<?php 
            } else {
                ?>

			<li>

				<?php 
                echo bp_core_fetch_avatar(array('item_id' => $mod->user_id, 'type' => 'thumb', 'alt' => sprintf(__('Profile picture of %s', 'buddypress'), bp_core_get_user_displayname($mod->user_id))));
                ?>

				<h5><?php 
                echo bp_core_get_userlink($mod->user_id);
                ?>
</h5>

				<span class="activity"><?php 
                echo bp_core_get_last_activity(strtotime($mod->date_modified), __('joined %s', 'buddypress'));
                ?>
</span>

				<?php 
                if (bp_is_active('friends')) {
                    ?>

					<div class="action">
						<?php 
                    bp_add_friend_button($mod->user_id);
                    ?>
					</div>

				<?php 
                }
                ?>

			</li>

			<?php 
            }
            ?>
		<?php 
        }
        ?>
//.........这里部分代码省略.........
开发者ID:kd5ytx,项目名称:Empirical-Wordpress,代码行数:101,代码来源:bp-groups-template.php

示例2: bp_member_name

                bp_member_name();
                ?>
</a>
							<span class="small">
								<a href="<?php 
                bp_group_member_promote_admin_link(array('user_id' => bp_get_member_user_id()));
                ?>
" class="button confirm mod-promote-to-admin" title="<?php 
                _e('Promote to Admin', 'buddypress');
                ?>
"><?php 
                _e('Promote to Admin', 'buddypress');
                ?>
</a>
								<a class="button confirm mod-demote-to-member" href="<?php 
                bp_group_member_demote_link(bp_get_member_user_id());
                ?>
"><?php 
                _e('Demote to Member', 'buddypress');
                ?>
</a>
							</span>		
						</h5>		
					</li>	
					<?php 
            }
            ?>
			
				
				</ul>
			
开发者ID:nxtclass,项目名称:NXTClass-themes,代码行数:30,代码来源:admin.php

示例3: do_action

         * @param $section Which list contains this item.
         */
        do_action('bp_group_manage_members_admin_item', 'admins-list');
        ?>
						</div>

						<div class="action">
							<a href="<?php 
        bp_group_member_promote_admin_link();
        ?>
" class="button confirm mod-promote-to-admin"><?php 
        _e('Promote to Admin', 'buddypress');
        ?>
</a>
							<a class="button confirm mod-demote-to-member" href="<?php 
        bp_group_member_demote_link();
        ?>
"><?php 
        _e('Demote to Member', 'buddypress');
        ?>
</a>

							<?php 
        /**
         * Fires inside the action section of a member admin item in group management area.
         *
         * @since 2.7.0
         *
         * @param $section Which list contains this item.
         */
        do_action('bp_group_manage_members_admin_actions', 'mods-list');
开发者ID:buddypress,项目名称:BuddyPress-build,代码行数:31,代码来源:manage-members.php

示例4: bp_group_mod_memberlist

function bp_group_mod_memberlist( $admin_list = false, $group = false ) {
	global $groups_template, $group_mods;

	if ( !$group )
		$group =& $groups_template->group;

	$group_mods = groups_get_group_mods( $group->id );
	?>
		<?php if ( $group_mods ) { ?>
			<ul id="mods-list" class="item-list<?php if ( $admin_list ) { ?> single-line<?php } ?>">
			<?php foreach ( (array)$group_mods as $mod ) { ?>
				<?php if ( $admin_list ) { ?>
				<li>
					<?php echo bp_core_fetch_avatar( array( 'item_id' => $mod->user_id, 'type' => 'thumb', 'width' => 30, 'height' => 30 ) ) ?>
					<h5><?php echo bp_core_get_userlink( $mod->user_id ) ?>  <span class="small"> &mdash; <a href="<?php bp_group_member_promote_admin_link( array( 'user_id' => $mod->user_id ) ) ?>" class="confirm" title="<?php _e( 'Promote to Admin', 'buddypress' ); ?>"><?php _e( 'Promote to Admin', 'buddypress' ); ?></a> | <a class="confirm" href="<?php bp_group_member_demote_link($mod->user_id) ?>"><?php _e( 'Demote to Member', 'buddypress' ) ?></a></span></h5>
				</li>
				<?php } else { ?>
				<li>
					<?php echo bp_core_fetch_avatar( array( 'item_id' => $mod->user_id, 'type' => 'thumb' ) ) ?>
					<h5><?php echo bp_core_get_userlink( $mod->user_id ) ?></h5>
					<span class="activity"><?php echo bp_core_get_last_activity( strtotime( $mod->date_modified ), __( 'joined %s ago', 'buddypress') ); ?></span>

					<?php if ( function_exists( 'friends_install' ) ) : ?>
						<div class="action">
							<?php bp_add_friend_button( $mod->user_id ) ?>
						</div>
					<?php endif; ?>
				</li>
				<?php } ?>
			<?php } ?>
			</ul>
		<?php } else { ?>
			<div id="message" class="info">
				<p><?php _e( 'This group has no moderators', 'buddypress' ); ?></p>
			</div>
		<?php }
}
开发者ID:n-sane,项目名称:zaroka,代码行数:37,代码来源:bp-groups-templatetags.php

示例5: bp_group_mod_memberlist

function bp_group_mod_memberlist($admin_list = false, $group = false)
{
    global $groups_template, $group_mods;
    if (!$group) {
        $group =& $groups_template->group;
    }
    $group_mods = groups_get_group_mods($group->id);
    ?>
		<?php 
    if ($group_mods) {
        ?>
			<ul id="mods-list" class="item-list<?php 
        if ($admin_list) {
            ?>
 single-line<?php 
        }
        ?>
">
			<?php 
        foreach ($group_mods as $mod) {
            ?>
				<?php 
            if ($admin_list) {
                ?>
				<li>
					<?php 
                echo bp_core_get_avatar($mod->user_id, 1, 30, 30);
                ?>
					<h5><?php 
                echo bp_core_get_userlink($mod->user_id);
                ?>
  <span class="small"> &mdash; <a href="<?php 
                bp_group_member_ban_link();
                ?>
"><?php 
                _e('Kick &amp; Ban', 'buddypress');
                ?>
</a> | <a href="<?php 
                bp_group_member_demote_link($mod->user_id);
                ?>
"><?php 
                _e('Demote to Member', 'buddypress');
                ?>
</a></span></h5>
				</li>
				<?php 
            } else {
                ?>
				<li>
					<?php 
                echo bp_core_get_avatar($mod->user_id, 1);
                ?>
					<h5><?php 
                echo bp_core_get_userlink($mod->user_id);
                ?>
</h5>
					<span class="activity"><?php 
                echo bp_core_get_last_activity(strtotime($mod->date_modified), __('joined %s ago', 'buddypress'));
                ?>
</span>
					
					<?php 
                if (function_exists('friends_install')) {
                    ?>
						<div class="action">
							<?php 
                    bp_add_friend_button($mod->user_id);
                    ?>
						</div>
					<?php 
                }
                ?>
				</li>		
				<?php 
            }
            ?>
			
			<?php 
        }
        ?>
			</ul>
		<?php 
    } else {
        ?>
			<div id="message" class="info">
				<p><?php 
        _e('This group has no moderators', 'buddypress');
        ?>
</p>
			</div>
		<?php 
    }
}
开发者ID:alvaropereyra,项目名称:shrekcms,代码行数:93,代码来源:bp-groups-templatetags.php


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