Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'notification user id'

Viewing 25 results - 426 through 450 (of 1,091 total)
  • Author
    Search Results
  • #240255
    Tom
    Participant

    So I did some tests…
    In a standard WordPress install users can enter spaces in their username.
    No problem.
    E.g. ‘Firstname Surname’ renders as just that, with a space between the words.

    But when I activate BuddyPress (no other plugins) with the Twenty Fifteen theme, suddenly the spaces are removed from the username. Without as much as a single notification or error message.
    E.g. ‘Firstname Surname’ becomes ‘FirstnameSurname’.

    This is a huge problem for users! As they don’t get a message their input has been changed. And the username is not mentioned in the activation e-mail.

    In my opinion there are two solutions:
    1. notify the user of the change during registration;
    2. allow the same username entry specification as WordPress does.

    So far I haven’t found any of these solutions. 🙁

    Need help.

    #239939
    Osisis
    Participant

    Not sure how to mark this topic resolved, but I’ve decided to go about this in another manner. I followed the BP model and have my admin bar acting in the capacity of a menu and deleted my primary menu. Is working out pretty well thus far. For anyone else that’s interested I

    Removed “howdy, $name” just because to me it screams WP

    function custom_adminbar_welcome() {
    	global $wp_admin_bar;
    
    		$name = wp_get_current_user()->display_name;
    		$avatar = get_avatar( wp_get_current_user()->ID, 28 );
    		$class = $class = empty( $avatar ) ? '' : 'with-avatar';
    
    		$wp_admin_bar->add_menu( array(
                    'id'    => 'my-account',
                    'title' => __('') . $avatar,
    				'class' => $class
    			) 
    		);
    }
    add_action( 'wp_before_admin_bar_render', 'custom_adminbar_welcome' );

    Removed WP links and change logo

    add_action( 'wp_before_admin_bar_render', 'custom_adminbar_welcome' );
    
    function rebranding_wordpress_logo(){
            global $wp_admin_bar;
            //the following codes is to remove sub menu
        $wp_admin_bar->remove_menu('about');            // Remove the about WordPress link
        $wp_admin_bar->remove_menu('wporg');            // Remove the WordPress.org link
        $wp_admin_bar->remove_menu('documentation');    // Remove the WordPress documentation link
        $wp_admin_bar->remove_menu('support-forums');   // Remove the support forums link
        $wp_admin_bar->remove_menu('feedback');         // Remove the feedback link
        $wp_admin_bar->remove_menu('site-name');        // Remove the site name menu
        $wp_admin_bar->remove_menu('view-site');        // Remove the view site link
        $wp_admin_bar->remove_menu('updates');          // Remove the updates link
        $wp_admin_bar->remove_menu('comments');         // Remove the comments link
        $wp_admin_bar->remove_menu('new-content');      // Remove the content link
        $wp_admin_bar->remove_menu('w3tc');             // If you use w3 total cache remove the performance link
     
            //and this is to change wordpress logo
            $wp_admin_bar->add_menu( array(
                'id'    => 'wp-logo',
                'title' => '<img src="http://test.theblackxperience.com/darklogo45.png" />',
                'href'  => __(home_url()),
                'meta'  => array(
                    'title' => __('eQubator'),
                ),
            ) );
            
    }
    add_action('wp_before_admin_bar_render', 'rebranding_wordpress_logo' );

    Moved BP child menus up to make them primary menus

    function make_parent_node( $wp_admin_bar ) {
    
    if ( ! is_user_logged_in() ) {
    		return false;
    	}
    
    	 $wp_admin_bar->add_node( array(
    		'id'     => 'my-account-activity',     // id of the existing child node (New > Post)
    		'title'  => '<span class="ab-icon"></span><span class="ab-item">'._x( '', '' ).'</span>', // alter the title of existing node
    		'parent' => false,          // set parent to false to make it a top level (parent) node
    	)); 
        $wp_admin_bar->add_node( array(
            'id'     => 'my-account-friends',     // id of the existing child node (New > Post)
    		'title'  => '<span class="ab-icon"></span><span class="ab-item">'._x( '', '' ).'</span>', // alter the title of existing node
    		'parent' => false,          // set parent to false to make it a top level (parent) node
    	));    
        $wp_admin_bar->add_node( array(
            'id'     => 'my-account-messages',     // id of the existing child node (New > Post)
    		'title'  => '<span class="ab-icon"></span><span class="ab-item">'._x( '', '' ).'</span>', // alter the title of existing node
    		'parent' => false,          // set parent to false to make it a top level (parent) node
    	));
       
    	$wp_admin_bar->add_node( $args );
    }
    add_action( 'admin_bar_menu', 'make_parent_node', 999 );

    Added CSS to turn the menu items into dashicons

    #wp-admin-bar-my-account-friends .ab-icon:before{
    	font-family: "dashicons" !important;
    	content: "\f307" !important;
    }
    #wp-admin-bar-my-account-messages .ab-icon:before{
    	font-family: "dashicons" !important;
    	content: "\f466" !important;
    }
    #wp-admin-bar-my-account-activity .ab-icon:before{
    	font-family: "dashicons" !important;
    	content: "\f130" !important;
    }
    
    #wpadminbar .quicklinks li#wp-admin-bar-bp-notifications>a:before{
    	font-family: "dashicons" !important;
    	content: "\f319" !important;
    }

    Only problem I’m having now is that for some reason the logo has decided to move itself to the right, but that’s another question for another topic. But hope this helps someone else. admin bar as menu

    @mcuk
    Participant

    These might help you @antoinegdln4:

    [Resolved] Position Notification Counter Bubble after Specific Navigation Tab ID

    https://buddypress.org/support/topic/help-customising-admin-bar-removing-links-from-dropdown/

    or removing WP admin bar entirely to all users except admin:

    function remove_admin_bar() {
    	if ( !current_user_can( 'administrator' ) && !is_super_admin() ) {
    	  show_admin_bar(false);
    	}
    }
    add_action( 'after_setup_theme', 'remove_admin_bar' );
    @mcuk
    Participant

    Hey @osisis,

    Glad to see you sorted it. This was my code:

    function bptest_main_nav_notification_bubble( $items, $args ) {
        if( $args->theme_location == 'header-menu' ) { // In manage locations via WP Dash>Appearance>Menus
        	$items_array = array();
            while ( false !== ( $item_pos = strpos ( $items, '<li', 3 ) ) ) {
                $items_array[] = substr( $items, 0, $item_pos );
                $items = substr( $items, $item_pos );
            }
            $items_array[] = $items;
            array_splice( $items_array, 3, 0, '<li id="bubble">' . bp_notifications_get_unread_notification_count( bp_loggedin_user_id() ) . '</li>' ); // 0,0 1st position, 1,0 2nd, etc
            $items = implode( '', $items_array );
        }
        return $items;
    }
    add_filter( 'wp_nav_menu_items', 'bptest_main_nav_notification_bubble', 10, 2 );
    

    I gave it the ID ‘bubble’. You can obviously give it a class if you want too (class=”bubbles”).

    totorosk8
    Participant

    Hi,
    i’ve been looking around, but i can’t figure why i have this problem.
    When i try to complete my registration i come back to the home screen, instead of going to the “activate” page. I checked on my buddypress options and the pages for register and activate are well indicated. I even tried the plugin “BP Disable Activation” but i always come back to the home screen and the user profile is not created.

    I’m on wordpress 4.2.2 with Buddypress V 2.2.3.1 .
    The Them is KLEO (the last version)
    all plugins are up to date :

    Allow PHP in Posts and Pages
    Bowe Codes
    BP Limit Group Membership
    Brozzme Cookie notification
    BuddyPress
    BuddyPress Group Plus
    BuddyPress Groups Extras
    Custom Contact Forms
    K Elements
    Open external links in a new window
    Postman SMTP (just for a test)
    Revolution Slider
    rtMedia for WordPress, BuddyPress and bbPress
    Taxonomy Metadata
    WPBakery Visual Composer
    WP Maintenance Mode
    WP Mobile Detect

    I tried to disable all the plugins, but still the same.
    When i try to register, i’m on another navigator and not logged on wordpress.
    Can some one help me please, i’m lost.

    Thanks a lot.

    Daxi
    Participant

    PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘bp_activity_heartbeat_last_recorded’ not found or invalid function name in […]/wp-includes/plugin.php on line 213

    This error will appear and make problems when BuddyPress Live Notifications is also installed.
    The function is defined in: /wp-content/plugins/buddypress/bp-activity/bp-activity-filters.php:530
    The filters will be added in lines: 580 and 581

    This will delete the response-array data from Live Notifications because the warning returns null.

    A temporarily fix is to set the priority of the Live Notification filter in /wp-content/plugins/bp-live-notifications/ajax.php to a value higher than 10.

    Steve
    Participant

    I have searched the forum for this and found many people asking about it, but I have yet to find a solution.

    When someone friends another person the All Members activity page shows “User X and User Y are now friends”. This ends up filling the entire page. Which is very annoying. Plus, for my clients purposes, this is absolutely useless.

    How do I get rid of this notification?? I just want “Updates” to show up.

    I found this article (https://codex.buddypress.org/developer/loops-reference/the-activity-stream-loop/#filtering-examples), but I am not a developer, so telling me to add a loop without telling me “where” to put it doesn’t help.

    Like I said, I have seen other people ask about this, but have yet to find the solution.

    Thanks in advance for the help.

    danbp
    Participant

    Two snippets to do this (hopefully). The first has a fixed position (latest by default), the second let’s you choose the position.

    function my_nav_menu_notif_counter($menu) {      
            if (!is_user_logged_in())
                    return $menu;
            else
                    $notif = '<li>Notif '. bp_notifications_get_unread_notification_count( bp_loggedin_user_id() ) .'</li>';
                    $menu = $menu . $notif;
                    return $menu;
    }
    add_filter( 'wp_nav_menu_items', 'my_nav_menu_notif_counter' );
    
    See comment how to apply a position
    function my_nav_menu_positioned_notif_counter( $items, $args ) 
    {
        if( $args->theme_location == 'primary' ) // only for primary menu
        {
            $items_array = array();
            while ( false !== ( $item_pos = strpos ( $items, '<li', 3) ) )
            {
                $items_array[] = substr($items, 0, $item_pos);
                $items = substr($items, $item_pos);
            }
            $items_array[] = $items;
            array_splice($items_array, 0, 0, '<li>Notif '. bp_notifications_get_unread_notification_count( bp_loggedin_user_id() ) .'</li>'); // 0,0 is first position, 1,0 is second, etc
    
            $items = implode('', $items_array);
        }
        return $items;
    }
    add_filter('wp_nav_menu_items','my_nav_menu_positioned_notif_counter', 10, 2);

    Reference: https://developer.wordpress.org/reference/hooks/wp_nav_menu_items/

    @mcuk
    Participant

    All the code I’ve used is in the post above. Not required any custom functions.

    The function: bp_notifications_get_unread_notification_count( bp_loggedin_user_id() ) was mentioned here:

    https://buddypress.org/support/topic/how-to-get-notification-count-code/

    Just echoing that function in my child header.php gives me exactly what i needed (along with the CSS i posted). Everything works fine.

    The only issue is to locate it within the menu itself in the correct location after the Notification tab, which i cannot do in the header file. At the moment I am only able to locate it within the container that holds the menu.

    The menu I am using I have created via WP > Appearance > Menus. Just a bog standard menu in the header of the page.

    @mcuk
    Participant

    Hi all,

    I am trying to insert a notification counter bubble within my main navigation menu after one specific ‘menu item li id’. Using the code below I have managed to display the counter correctly on the page but am unable to work out how to place it where I want after the desired menu item. Can anyone offer any pointers?

    I already have the code to display the notification counter:

    echo bp_notifications_get_unread_notification_count( bp_loggedin_user_id() );

    I then added it to my theme’s child header.php within the main menu container div and gave it it’s own div & id to enable styling:

    <div id="testid"><?php echo bp_notifications_get_unread_notification_count( bp_loggedin_user_id() ); ?></div>

    (Putting it here was just a test to see if the echo and CSS were correct).

    The CSS which makes it appear correctly:

    #testid {
    	background: #eee;
    	border-radius: 50%;
    	border: 1px solid #ccc;
    	color: #000;
    	display: inline;
    	font-size: 70%;
    	margin-left: 2px;
    	padding: 3px 6px;
    	text-align: center;
    	vertical-align: middle;
    }

    I ran a search for ‘notification counter’ along with a few other things but didn’t come across a recognisable solution.

    Thanks

    #238535
    xprt007
    Participant

    Hi

    I posted this in the bbpress forum & I was told all these pages have to do with buddypress & was directed to Buddypress support.

    I have a community site with a number of plugins, including bbforum & buddypress.
    I noticed when a member posted a reply to forum content, that when I clicked on the notification bubble /members/user/notifications/, it led a page not found error.

    I tried to check my profile as forum user, top right and cannot access any of the pages which all lead to same error.

    I tried re-saving permalinks (a few plugins I have require them in any case) …, not knowing what to do next and still have this error. /members/ is accessible, but not any of the pages if u click a listed member page.
    Also checked the bbforum/buddypress settings & could not see what is not OK.

    I am not quite sure when this error could have started, as I have not used these links for many months, but probably someone may know what is causing it – and would appreciate some some help to get rid of it.

    Even /groups/group-name/ is not not accessible.

    Outside bbforum/buddypress, there are NO link problems.

    Link: http://bit.ly/1FPSfDK

    Thank you in advance

    #237907
    netweavers
    Participant

    I want to change user profile tabs links (activity, profile, notifications… and so on), I have very long member-header content on profile pages and I want tabs to have div #id in the link:

    Standard PROFILE tab link:
    http://www.domain.com/members/admin/profile/

    I want it to be:
    http://www.domain.com/members/admin/profile/#profile

    How can I change it?

    #237902

    In reply to: Chat plugin?

    djsteveb
    Participant

    So what op is saying, is that basically taking the notifications from the top right and putting “inbox notifications” on the bottom right of the screen, and when hover / clicked would bring up latest messages, and instead of clicking those bring you to a new bp page, it could ajax load your private messages – and allow for image uploads.. would kind of do what you are talking about.. no fancy chat required.. kind of I guess?

    I use quick chat on one site with a dedicated server, and only enable it to work on one page, not show up on every page of the site.. I use av-chat (from nusoft I think) on a busier site.. but with my sites I am not using them in the way the OP is asking about, a mini chat tab on each page.. I just use them as chat rooms on a single page.

    Tried many other solutions, paid for many, most fail miserably starting around 20 users.

    /random thoughts at 2am

    Kashif Rafique
    Participant

    I have tried to search a solution, but unable to find it. Can someone guide me in the right direction how can I modify following notification after user activation?

    <div class="page" id="activate-page">
    	<div class="bp-template-notice updated" id="message">
    		<p>Your account is now active!</p>
    	</div>
    	<p>Your account was activated successfully! You can now <a href="http://example.com/wp-login.php?redirect_to=http%3A%2F%2Fexample.com">log in</a> with the username and password you provided when you signed up.</p>
    </div><!-- .page -->
    #237321
    danbp
    Participant

    hi @dingxiaohan,

    default general usage of notification is explained on our Codex:
    https://codex.buddypress.org/member-guide/notifications/

    Each topic can be followed by the author and all who answer on a per topic base. Email you’ll receive in this case will show the topic url and a brief excerpt.

    A little different is BP Live Notification plugin, which add a Facebook Like real-time notification for user.

    Some other way to use and show notification can be done by coding a little, which is explaine here.

    #237320
    dingxiaohan
    Participant

    As a total novice I’ve put together a site for my local community, http://www.listraban.net. I want to add a means of communication and debate using bodypress and bbpress. The major issue is how it integrates with users’ email. My ideal would be the system that Yahoo groups use, wherein the user can, without help from a moderator, choose to get by email either (a) every new post, (b) a daily digest of new posts or (c) nothing at all. I’ve tried reading what there is about notification plug-ins, but understand hardly a word. For a start I don’t know whether “notification” means an email containing the text of a post, or an email simply announcing that there is a new post.

    I believe the WordPress theme is 2012, FWIW. BuddyPress version can be whatever it is if we ever get started.

    #237299
    5high
    Participant

    Brilliant! It worked a treat, and I used the ‘user_register’ as suggested. So for anyone else looking for this solution, this is the code i used to turn some on and some off by default on new user registration:

    add_action( 'user_register', 'bpdev_set_email_notifications_preference');
    function bpdev_set_email_notifications_preference( $user_id ) {
    //I am putting some notifications to no by default and the common ones to yes to enable it.
    //ref. https://bp-tricks.com/snippets/changing-default-buddypress-notifications-settings and BP forum
    $settings_keys = array(
    'notification_activity_new_mention' => 'yes',
    'notification_activity_new_reply' => 'yes',
    'notification_friends_friendship_request' => 'no',
    'notification_friends_friendship_accepted' => 'no',
    'notification_groups_invite' => 'no',
    'notification_groups_group_updated' => 'no',
    'notification_groups_admin_promotion' => 'no',
    'notification_groups_membership_request' => 'no',
    'notification_messages_new_message' => 'yes',
    );
    foreach( $settings_keys as $setting => $preference ) {
    bp_update_user_meta( $user_id, $setting, $preference );
    }
    }

    and this went in my child theme functions.php file.
    Hooray! Thanks so much again – it will make a big different to our users experience.
    Cheers 🙂

    #237014
    mrgiblets
    Participant

    I should add that i’ve got a part of it working by echoing the following where I want it to appear but it’s obviously just echoing the numerical count and I want the full functionality of the BP notification tab with links and descriptions of the items.

    echo bp_notifications_get_unread_notification_count( bp_loggedin_user_id() );

    #237012
    mrgiblets
    Participant

    Hey guys,

    I’d like to disable the activity notifications tab that currently resides in the WP admin bar for each user and display it elsewhere on the site (i.e my own custom navigation bar).

    I found this old thread which seemed to do exactly what I was after but the code snippet from modemlooper has since been deleted – https://buddypress.org/support/topic/how-to-implement-user-notifications-to-template-without-admin-bar/

    Could somebody please point me in the right direction and please bear in mind that i’m a BP newbie 🙂

    mrgiblets
    Participant

    Hey guys,

    Been a wordpress user/developer for years and I know my way around WP pretty well (within reason).

    I wanted to add some social interaction to a new site that i’m building so I decided to give buddypress a whirl.

    I have to say that, once I got it working, I was really impressed at what BP offers.

    Please don’t shoot me down but I have some valid criticisms with the support docs and available support for even getting a buddypress install off the ground.

    1) WP 4.1 / BP 2.2.1 (which is my set up)
    After a clean install of WP 4.1 and BP 2.2.1 BP didn’t set up the required default pages. I eventually figured out that I could just create blank Members / Activity etc pages and it worked but this took me hours to figure this out which leads me on to the next issue.

    2) When googling for help with the issues i’ve experienced most of the results I found were years old and not even relevant to my current install. Furthermore, when I did actually get it up and running and wanted to start playing with the layout and functionality, all the help topics I could find that had code snippets (hooks etc) are no longer available.

    3) Plug in support seems to be outdated at best. I know this isn’t the fault of BP, but it seems that there is quite a bit of required functionality that really should ship with a basic BP install. A lot of this has been addressed by plug ins, but most of these haven’t been updated for years and don’t work with a current install properly.

    Examples of things that I feel should be standard :

    – Setting email notifications site wide for new users (I can’t imagine any webmaster would be happy about sending out thousands of emails everyday for every single action that a user on the site makes). This is a critical update that needs to be implemented.

    – When typing a message using “@” the dropdown list that pops up as soon as your start typing should only show names of the current users friends. What happens if you have 10,000+ users on your site? That’s going to get annoying for the users really fast. At very least there should be an option in the backend to activate this functionality.

    – LIKE button. I wasn’t that surprised that something like this wasn’t installed as standard, but as this is an integral part of social interaction these days I was shocked after spending days trying to find a plug-in that works with the current version and have only managed to find one that works but is shaky at best. There are lots of “no longer available” plug-ins and bits of code and hacks out there but again – removed or deleted when you try to view them. From what I gather this seems to be something that developers have had real problems implementing. I can’t even find a single premium LIKE button plug-in out there! Surely it’s time to have this feature as standard?

    4) I’m all for getting stuck in and even sharing what I learn with the BP community but the BP support docs are very sparse and could be so much better, especially for new users. I’m not a WP newbie but I’m having a real hard time trying to make sense of it all.

    5) A clean current install of BP doesn’t include a BP theme. I have read that you have removed this and tried to implement it with any standard WP theme but that doesn’t help new users when trying to figure out what BP is capable of. Despite formatting issues many of the things it can do simply aren’t that obvious with a default WP theme. Surely it should at least give you the option to install a standard BP theme from theme manager?

    Again, please don’t take any of what i’ve said in the wrong way. So far i’m very impressed with what Buddypress is capable of but I wanted to share the thoughts of a new user in the hope that you could have a look at some of these issues for a future release.

    On another note, it took me about 5 minutes to find the link for creating a topic on the forum here too. Maybe this is the standard BP forum set up, but as a new user this could be much clearer.

    For now i’m going to stick with it and get my head down and try to figure out the stuff I need to change for my desired set up, so I’m sure you’ll be seeing a lot of me on these forums – if you’ll still have me after this post 😉

    mcpeanut
    Participant

    @henrywright YOU MY FRIEND ARE A STAR! 🙂 This is exactly what i was looking for and can confirm its working for me, i have now got the mentions split out with the number of mentions displayed and working correctly, thankyou very much henry!!!! also thankyou very much @danbp for your help. This is resolved! cheers.

    Oh one last thing henry it turns out i didnt need to use the echo $count; at the end because it was causing it to echo 4 times on the page, but removing it seemed to fix the problem and the count is still showing.

    So the final code i used was

    $query_vars = array(
    	'user_id' => get_current_user_id(),
    	'component_action' => 'new_at_mention',
    	'is_new' => true
    );
    $count = BP_Notifications_Notification::get_total_count( $query_vars )

    ty once again henry.

    mycru.io
    Participant

    My website: http://www.kawaii.com
    My theme: Seventhqueen KLEO

    Hi I checked today my debug.log and I found this here ( there are many: Duplicate entry ‘plugin buddypress- entries)
    How can I fix that ? Anyone an idea ? Really appreciate !!!

    [25-Feb-2015 21:02:18 UTC] WordPress database error Duplicate entry ‘plugin buddypress-3e4c9c2f65c064f07f8ef075fd946a2c’ for key ‘context_name’ for query UPDATE u5sbqr_icl_strings SET name = ‘3e4c9c2f65c064f07f8ef075fd946a2c’ WHERE context = ‘plugin buddypress’ AND name = ’09b57733b0c38d449fe713f0eb8b090a’ made by require(‘wp-blog-header.php’), require_once(‘wp-load.php’), require_once(‘wp-config.php’), require_once(‘wp-settings.php’), do_action(‘init’), call_user_func_array, bpml_update_email_notifications_strings, icl_rename_string

    EDIT: please don’t post such long log report when concerning only one issue.

    Henry Wright
    Moderator

    Hey again @mcpeanut,

    I’ve had a little bit more time this evening to look at this for you. I found that the notifications component provides a public static method get_total_count() which can be used to get the unseen mention count. You can use it like this:

    $query_vars = array(
    	'user_id' => get_current_user_id(),
    	'component_action' => 'new_at_mention',
    	'is_new' => true
    );
    $count = BP_Notifications_Notification::get_total_count( $query_vars );
    echo $count;

    Hope that does the trick!

    mcpeanut
    Participant

    @henrywright using this bp_activity_format_notifications( $user_id = 0 ); i have got the mentions to show in the dropdown but without the username of who mentioned you until you hover over it, there is no count though.

    #236799
    5high
    Participant

    Update:

    well i’ve just tested option #1 and it didn’t work – my test new user had all email notifications still set to ON as the default.

    and # 2 code didn’t work either – all set to ON.

    Maybe @henrywright or @nd1 could throw some light on this if possible, as their thread is now closed??

    Or any other ideas would be much appreciated – thanks heaps.

Viewing 25 results - 426 through 450 (of 1,091 total)
Skip to toolbar