Skip to:

BuddyPress Inbox count on bbPress Login

  • joejozwowski


    I have a site that uses both BuddyPress and bbPress functionality. On the sidebar, for users to log in, they are using the bbPress Login Widget and from there they can access their buddyPress profile.

    I would like to display the user’s inbox count in the bbPress widget once they have successfully logged in. I have currently displaying the user’s name which links to their buddyPress profile, a link to the wordpress dashboard if their WordPress role is either Author, Editor or Administrator and a Log Out button. Here is my code:

    <div class="bbp-logged-in">
        <table width="100%" border="0" cellspacing="5" cellpadding="5">
            <tr valign="top">
                <td width="60px" align="right" valign="top">
                	<a href="<?php bbp_user_profile_url( bbp_get_current_user_id() ); ?>" class="submit user-submit"><?php echo get_avatar( bbp_get_current_user_id(), '56' ); ?></a>
                <td align="left" valign="top">
                	<h4 style="margin: 2px 0; padding:2px 0;"><?php bbp_user_profile_link( bbp_get_current_user_id() ); ?></h4>
                	<?php if ( current_user_can('author') || current_user_can('editor') || current_user_can('administrator')) : ?>
                		<h4 style="margin: 2px 0; padding:2px 0;"><a href="<?php bloginfo('url'); ?>/wp-admin">CPN Dashboard</a></h4>
                	<?php endif; ?>
                	<?php bbp_logout_link(); ?>

    Any Suggestions?

  • The topic ‘BuddyPress Inbox count on bbPress Login’ is closed to new replies.
Skip to toolbar