Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for '@mention on profile'

Viewing 25 results - 51 through 75 (of 129 total)
  • Author
    Search Results
  • #184395
    tuffo
    Participant

    Hi!

    I’m new to Buddypress and this will be my first post here. I’m working on some customizations of the user profiles on my site. Now I want to remove the “Favorites” button/function but I can’t figure out how to do it. I tried to add the following to my bp-custom.php

    add_filter( ‘bp_activity_can_favorite’, ‘__return_false’ );

    …but without luck. And trust me, I’ve done my googling on this 🙂

    I’ve done the same thing to the “@mentions” button by adding the following code to bp-custom.php

    add_filter( ‘bp_activity_do_mentions’, ‘__return_false’ );

    …and this works perfectly!

    Anyone who can point me in the right direction?

    Thanks!
    Fredrik

    producist
    Participant

    Hi @imath,

    We connected on Twitter and you asked me to @mention you to help me with my problem with BP My-Home plugin.

    I love this plugin, however when I have it activated and deactivated, I have problems with my website. I’m using the latest version of WordPress and Buddypress.

    When Activated: I can’t go to any buddypress member page except my own; Or anytime I try to use this url structure “site.com/members/USERNAME” I get a “This webpage has a redirect loop” SEE IMAGE BELOW

    http://s24.postimg.org/bewuoufqd/http_producia_staging_wpengine_com_members_cau.png

    When Deactivated: I can’t see anyone’s members page. I get this error

    http://s8.postimg.org/b1l5p5v51/Fiverr_Help_s_Profile_Producia.png

    Please help, as we’re looking to go live this Saturday.

    Thanks in advance!

    http://wordpress.org/plugins/bp-my-home/

    #176741
    scimea
    Participant

    @mossyoak How did you accomplish that?

    I need a solution that allows only the user (and the admin) to see their own profile. I need it so members not involved (@mentioned) in conversations on activity strea cannot see them.

    Only the members involved and the admin should be able to see the conversation.

    Thanks,
    Adam

    distortedview
    Participant

    I have a unique problem, I think. I have a subscription member based site, and prior to my current system, the users were forced to use email addresses as their username. When I migrated to the new system, the email addresses-as-usernames were imported.

    I’m trying to implement Buddypress but it wants to display their usernames, and a lot of my users don’t want their email address as public info.

    Specifically, when posting to a group or replying, and also on their profile (the @mention name)

    IS their a way to completely get rid of displaying the usernames, and instead display their nickname or displayname?

    #169743
    David Cavins
    Keymaster

    You can use r-a-y’s code to remove that pane:

    //Removes mentions pane from profile activity (doesn't remove mention functionality)
    function ray_remove_mention_nav() {
    global $bp;
    bp_core_remove_subnav_item( $bp->activity->slug, 'mentions' );
    }
    add_action( 'bp_setup_nav', 'ray_remove_mention_nav', 15 );

    It works on my 1.8+ test setup.

    -David

    #169410
    ultimateuser
    Participant

    Hi,

    I’m using WP 3.6 and BP 1.8

    I’ve added add_filter('bp_activity_do_mentions', '__return_false');

    to my bp-custom.php file.

    However when I visit a Members Profile Page the @mention still displays below the name field.

    Any suggestions?

    Thank you

    #164468
    redknite
    Participant

    The site i’m working on is www .fishwire.net. I have it all running but one of the main problems is the @mentions. When someone posts a comment it uses their full name “john smith” says… However john smith’s @John-smith How can i make them the same? The @name would promote the function where as you have to go to the individuals profile in order to find out what their @name is in order to respond to someone.

    Thanks!

    nawakiri
    Participant

    I have been trying to find out ways to implement a Facebook-like “write on wall” or “post to profile” functionality, and it seems that I am not alone. After some research, I was lead to this very helpful article written by Brajesh Singh in 2010:

    Using activity as wire in Buddypress 1.2 themes

    This is a brief report how I adapted the mod to WordPress 3.4.2 + Buddypress 1.6.1 + Buddpress Template Pack 1.2.1. So far everything seems to work. In case of any confusion, this mod does not exactly implement Facebook write-to-wall. The trick here is to enable the status update form on profiles and, when it is used in the profile of user X, append a short piece of text @mentioning user X. The status will thus show up later in X’s “Mention” tab. It will look more like write-to-wall if I manage to combine the “Personal” and “Mention” streams into one, another mod many people seem to want to have.

    I am using not the bp-default theme but Twenty-Eleven + Buddpress Template Pack 1.2.1. All the mods suggested by Brajesh Singh basically still work, modulo different locations and some code updates. Please refer to Brajesh’s original article. The following describes the difference.

    For Step 1, find lines 65-66 in members/single/activity.php

    if ( is_user_logged_in() && bp_is_my_profile() && ( !bp_current_action() || bp_is_current_action( 'just-me' ) ) )
    locate_template( array( 'activity/post-form.php'), true );

    Change line 65 to

    if ( is_user_logged_in() && ( !bp_current_action() || bp_is_current_action( 'just-me' ) ) )

    For Step 2, find line 38 of activity/post-form.php

    <?php if ( bp_is_active( 'groups' ) && !bp_is_member() && !bp_is_group() ) : ?>

    Change to

    <?php if ( bp_is_active( 'groups' ) && !bp_is_member() && !bp_is_group() ) : ?>

    For Step 3, in functions.php of your theme (create this file if it does not exist)

    <?php

    function bpdev_remove_post_update(){
    remove_action( 'wp_ajax_post_update', 'bp_dtheme_post_update' );
    }

    add_action("init","bpdev_remove_post_update");

    add_action( 'wp_ajax_post_update', 'bp_mytheme_post_update' );

    /* AJAX update posting */
    function bp_mytheme_post_update() {
    global $bp;

    /* Check the nonce */
    check_admin_referer( 'post_update', '_wpnonce_post_update' );

    if ( !is_user_logged_in() ) {
    echo '-1';
    return false;
    }

    if ( empty( $_POST['content'] ) ) {
    echo '-1' . __( 'Please enter some content to post.', 'buddypress' ) . '';
    return false;
    }

    if ( empty( $_POST['object'] ) && function_exists( 'bp_activity_post_update' ) ) {

    if(!bp_is_home() && bp_is_member())
    $content="@". bp_get_displayed_user_username()." ".$_POST['content'];
    else
    $content=$_POST['content'];

    $activity_id = bp_activity_post_update( array( 'content' => $content ) );

    } elseif ( $_POST['object'] == 'groups' ) {
    if ( !empty( $_POST['item_id'] )&&function_exists( 'groups_post_update' ) )
    $activity_id = groups_post_update( array( 'content' => $_POST['content'], 'group_id' => $_POST['item_id'] ) );
    } else
    $activity_id = apply_filters( 'bp_activity_custom_update', $_POST['object'], $_POST['item_id'], $_POST['content'] );

    if ( !$activity_id ) {
    echo '-1' . __( 'There was a problem posting your update, please try again.', 'buddypress' ) . '';
    return false;
    }

    if ( bp_has_activities ( 'include=' . $activity_id ) ) {
    while ( bp_activities() ) {
    bp_the_activity();
    locate_template( array( 'activity/entry.php' ), true );
    }
    }
    }

    ?>

    The code above is mostly the same as that of Brajesh Singh, apart from the beginning. Brajesh’s code starts with:

    remove_action( 'wp_ajax_post_update', 'bp_dtheme_post_update' );
    add_action( 'wp_ajax_post_update', 'bp_mytheme_post_update' );

    It didn’t work for me — my status updates got duplicated. I then found somewhere else that it didn’t work for themes other than bp-default. If you use bp-default, you might need Brajesh’s version.

    Hope the above helps.

    #32579
    ImaCrayon
    Participant

    If an author creates a blog post then later updates the post using an @mention somewhere in the post’s contents, the new mention will link to the user’s profile like it is suppose to. However it will not show up in the user’s profile under ‘Mentions’. How can I fixing this issue?

    #143406
    teorourke
    Participant

    Ah nevermind! It seems it’s part of the theme design. I’ve gone ahead and posted on their forums on how to get it back. Thanks anyway!

    #143399
    @mercime
    Keymaster

    Did you add a plugin recently? If you change to bp-default theme, do the mentions show up?

    #32413
    teorourke
    Participant

    For some reason I only just now noticed this. The @mention isn’t showing up in the profile on my site. What could I have done to disable this? I’d like to have it back.

    George
    Participant

    If you go to your profile or the activity stream and type in @admin I get a notification.

    Do it on the forums, no notification.

    jakeyboy1989
    Member

    no help or ideas?

    jakeyboy1989
    Member

    Anyone have any ideas on this?

    Is this a feature or a bug?

    jakeyboy1989
    Member

    hi,

    having some issues with bp putting auto links on profile to twitter, specifically @mention part – http://new.progressivetalks.com/members/jakewhitehead/

    why is this and how can i control it?

    Also is it possible to edit the@ mention id?

    thanks

    #28084
    bigt11
    Participant

    **UPDATED**
    -when multiple results show, it will show the AKA @ name properly now
    -added the same limit on the results returned that the original code used

    Like a lot of people, I want the auto suggest to look for display names and nice names. Below is my code to do just that. Im using a $wpdb->get_results to do my search. Im also changing up the displayed text to also include that users nice name so if the user is searching for “bob”. A user’s display name might be “bob9”, but there login = “I_am_bob” It will display avatar then display name then @username

    example output
    [avatar] bob9 AKA -> @i_am_bob

    Warning im not a coding master, but it seems to work for me. Below is the whole class-bplabs-autosuggest.php so just make a backup of your site, and overwrite inside class-bplabs-autosuggest.php with the code below

    <?php
    /**
    * @package BP_Labs
    * @subpackage Mentions_Autosuggest
    */
    
    // Exit if accessed directly
    if ( !defined( 'ABSPATH' ) )
    exit;
    
    /**
    * Implements the <a href='http://buddypress.org/community/members/message/' rel='nofollow'>@message</a> autosuggest experiment.
    *
    * <a href='http://buddypress.org/community/members/since/' rel='nofollow'>@since</a> 1.0
    */
    class BPLabs_Autosuggest extends BPLabs_Beaker {
    /**
    * Enqueue javascript
    *
    * <a href='http://buddypress.org/community/members/since/' rel='nofollow'>@since</a> 1.0
    */
    public function enqueue_script() {
    $dir = WP_PLUGIN_URL . '/bp-labs/beakers/js/jquery.mentions';
    
    if ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG )
    wp_enqueue_script( 'bplabs-autosuggest-js', "{$dir}.dev.js", array( 'jquery' ), '1.2' );
    else
    wp_enqueue_script( 'bplabs-autosuggest-js', "{$dir}.js", array( 'jquery' ), '1.2' );
    
    wp_localize_script( 'bplabs-autosuggest-js', 'BPMentions', array(
    'error1'     => __( 'Sorry, an error occurred.', 'bpl' ),
    'error2'     => _x( 'Please try again.', 'an error occurred', 'bpl' ),
    'searching'  => _x( 'Searching for members to mention... one moment please...', 'started a search', 'bpl' )
    ) );
    
    // This bit of javascript is what you could add directly to your theme
    $dir = WP_PLUGIN_URL . '/bp-labs/beakers/js/autosuggest';
    
    if ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG )
    wp_enqueue_script( 'bplabs-autosuggest-theme-js', "{$dir}.dev.js", array( 'bplabs-autosuggest-js' ), '1.0' );
    else
    wp_enqueue_script( 'bplabs-autosuggest-theme-js', "{$dir}.js", array( 'bplabs-autosuggest-js' ), '1.0' );
    }
    
    /**
    * Enqueue CSS
    *
    * <a href='http://buddypress.org/community/members/since/' rel='nofollow'>@since</a> 1.0
    */
    public function enqueue_style() {
    $dir = WP_PLUGIN_URL . '/bp-labs/beakers/css/jquery.mentions';
    
    if ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG )
    wp_enqueue_style( 'bplabs-autosuggest', "{$dir}.dev.css", array(), '1.0' );
    else
    wp_enqueue_style( 'bplabs-autosuggest', "{$dir}.css", array(), '1.0' );
    }
    
    /**
    * Add the AJAX callback for the mention_autosuggest() method.
    *
    * <a href='http://buddypress.org/community/members/since/' rel='nofollow'>@since</a> 1.0
    */
    protected function register_actions() {
    add_action( 'wp_ajax_activity_mention_autosuggest', array( 'BPLabs_Autosuggest', 'mention_autosuggest' ) );
    }
    
    /**
    * AJAX receiver for the @mention autosuggest jQuery library. Performs a search on the string provided and returns matches.
    *
    * <a href='http://buddypress.org/community/members/global/' rel='nofollow'>@global</a> object $bp BuddyPress global settings
    * @return mixed Either HTML or JSON. If error, "-1" for missing parameters, "0" for no matches.
    * <a href='http://buddypress.org/community/members/see/' rel='nofollow'>@see</a> bp-labs/beakers/js/jquery.mentions.dev.js
    * <a href='http://buddypress.org/community/members/since/' rel='nofollow'>@since</a> 1.0
    */
    public function mention_autosuggest() {
    global $bp;
    
    if ( empty( $_POST ) || empty( $_POST ) )
    exit( '-1' );
    
    // Sanitise input
    $search_query = implode( '', (array) preg_replace( array( '|^https?<img src="smileys/irritated.gif" width="" height="" alt=":/" title=":/" class="bbcode_smiley" />/|i', '|*|', '|@|' ), '', $_POST ) );
    if ( empty( $search_query ) )
    exit( '-1' );
    
    //$args = array(
    //	'count_total' => false,
    //	'number'      => (int) $_POST,
    //	'search'      => "{$search_query}*"
    //);
    
    if ( !empty( $bp->loggedin_user->id ) )
    $args = array( $bp->loggedin_user->id );
    
    if ( bp_is_username_compatibility_mode() ) {
    //$args  = array( 'ID', 'user_login' );
    //$args = 'login';
    
    }
    else {
    //$args  = array( 'ID', 'display_name' );
    //$args = 'nicename';
    }
    
    $args = apply_filters( 'bpl_mention_autosuggest_args', $args );
    
    // Search users
    //TAO custom search using display name
    global $wpdb;
    $TAO_limit_results = (int) $_POST;
    $user_search_results = $wpdb->get_results( "SELECT ID, user_nicename, display_name, user_login FROM wp_users WHERE user_login like'%$search_query%' OR display_name like '%$search_query%' LIMIT 0, $TAO_limit_results" );
    //print_r($user_search_results);
    echo "<br>";
    echo 'Searching for members to mention with "' .$search_query .'" in their name.';
    echo "<br>";
    echo 'Click on the user you wish to mention.';
    $args = array(
    'search'      => "*{$search_query}*"
    
    );
    //$user_search_results = new WP_User_Query( $args );
    //print_r($user_search_results);
    if ( empty( $user_search_results ) ) {
    
    // Return JSON
    if ( !empty( $_POST ) && 'json' == $_POST ) {
    exit( json_encode( false ) );
    
    // Return HTML
    } else {
    printf( '<li class="section error"><span>%s</span> %s
    </li>', _x( 'No matches found.', 'no search results', 'bpl' ), _x( 'Please check your spelling.', 'no search results', 'bpl' ) );
    exit();
    }
    }
    
    // If logged in, get user's friends
    $friend_ids = array();
    if ( !empty( $bp->loggedin_user->id ) && bp_is_active( 'friends' ) )
    $friend_ids = friends_get_friend_user_ids( $bp->loggedin_user->id );
    
    $search_results = array( 'friends' => array(), 'others' => array() );
    
    // Build results
    foreach ( (array) $user_search_results as $user ) {
    $result         = new stdClass;
    $result->avatar = bp_core_fetch_avatar( array( 'item_id' => $user->ID, 'width' => 30, 'height' => 30, 'type' => 'thumb', 'alt' => __( 'Profile picture of %s', 'bpl' ) ) );
    $result->name   = bp_core_get_user_displayname( $user->ID );
    //TAO adding the nicename to do a AKA
    $result->TAO_user_nicename = $user->user_nicename;
    
    if ( bp_is_username_compatibility_mode() )
    $result->id = $user->user_login;
    else
    $result->id = $user->user_nicename;
    
    if ( in_array( $user->ID, (array) $friend_ids ) )
    $search_results[] = $result;
    else
    $search_results[]  = $result;
    }
    
    apply_filters_ref_array( 'bpl_mention_autosuggest', array( &$search_results, $args ) );
    
    // Return JSON
    if ( !empty( $_POST ) && 'json' == $_POST ) {
    exit( json_encode( $search_results ) );
    
    // Return HTML
    } else {
    $html = array();
    
    foreach ( $search_results as $section => $items ) {
    if ( empty( $items ) )
    continue;
    
    // Friends and other users
    if ( 'friends' == $section || 'others' == $section ) {
    if ( 'friends' == $section ) {
    $html[] = sprintf( '<li class="section friends">%s
    </li>', __( 'Your friends', 'bpl' ) );
    
    } elseif ( 'others' == $section ) {
    if ( !empty( $search_results ) )
    $html[] = sprintf( '<li class="section other">%s
    </li>', sprintf( __( 'Other people on %s', 'bpl' ), get_bloginfo( 'name', 'display' ) ) );
    else
    $html[] = sprintf( '<li class="section other">%s
    </li>', sprintf( __( 'People on %s', 'bpl' ), get_bloginfo( 'name', 'display' ) ) );
    }
    
    foreach ( $items as $item )
    $html[] = sprintf( '<li class="%s">%s
    </li>', esc_attr( $item->id ), $item->avatar . esc_html( $item->name ) . '&nbsp;&nbsp&nbsp;&nbsp;AKA&nbsp;&nbsp;---> @' .$item->TAO_user_nicename );
    
    // For third-party extensions
    } else {
    $custom_section = apply_filters( 'bpl_mention_autosuggest_custom_section', false, $section, $items );
    
    if ( !empty( $custom_section ) )
    $html = array_merge( $html, (array) $custom_section );
    }
    }
    
    // Safety net
    if ( empty( $html ) )
    $html[] = sprintf( '<li class="section error"><span>%s</span> %s
    </li>', _x( 'No matches found.', 'no search results', 'bpl' ), _x( 'Please check your spelling.', 'no search results', 'bpl' ) );
    
    exit( apply_filters( 'bpl_mention_autosuggest_html', implode( PHP_EOL, $html ), $html ) );
    }
    }
    }
    new BPLabs_Autosuggest();
    ?>
    Lemmy
    Participant

    Hi,
    I’m using Buddypress for an academic blogging system. We don’t want students’ usernames to be visible in the system to other users, alongside their real names. The display names are populated by LDAP values.
    I have disabled @mentions, which use the username values. All I need to do now (I think) is change the urls of members’ profile pages, which currently use the studentID. e.g:
    http://domainname.ac.uk/members/zhe11341841/

    Is it possible to rewrite these to use another unique identifier, such as member ID? e.g.
    http://domainname.ac.uk/members/751

    Thanks!

    #119536
    Paul Wong-Gibbs
    Keymaster

    BuddyPress doesn’t use Facebook’s wall idea. It’s more like Twitter; you need to @mention them. The default theme has a “public message” button when viewing another user’s profile; this is a shortcut and it provides the @mention for you.

    tjbrewers
    Participant

    What is the ‘?’ on member profile page in profile-header (next to the @mention)? What does it do? How can I enable it to do something?

    #114544
    gregfielding
    Participant

    @katemgilbert

    It’s not that the profiles are broken, but that the activity and @mention permalinks for prior events aren’t updated. New activity will have the correct, new link, while prior activity links will be broken.

    I’ll let you know if I have any more luck with this!

    #111379
    Virtuali
    Participant

    If you want to have it on a different page, just change the permalink on the profile to something different, or “URL”. This may help. https://codex.buddypress.org/extending-buddypress/customizing-labels-messages-and-urls/

    #111298
    Michael Eisenwasser
    Participant

    I have long thought BuddyPress was confusing, and so I decided to take on the task of building a theme that would solve every issue I have with BuddyPress. It can be downloaded at http://www.buddyboss.com.

    1. Groups and Forums are combined in an INTUITIVE way on my theme. It finally makes sense!
    2. @mentions are gone. In their place is a TRUE Facebook wall on every profile. Post on friend’s profiles and status updates with threaded comments. You’ve got to try it to see how sweet it is :)
    3. Stripped out all of the nonsense that adds to BuddyPress’ general chaos, and what’s left is a simple and enjoyable experience.

    Michael Eisenwasser
    Participant

    Here’s the answer! It has always frustrated me how @mentions work in BuddyPress as I find it chaotic and confusing for users. So I built a theme that converts the @mentions system into a TRUE Facebook wall with post to profile and threaded replies. If you every need to, at any time you can deactivate our Wall Component from the dashboard and your content will revert to @mentions, You can download the theme at http://www.buddyboss.com.

    #111294
    Michael Eisenwasser
    Participant

    I created a theme that comes with a true Facebook wall. It converts all @mentions into Wall posts that can be replied to and threaded on your profile and is extremely intuitive to use, and it makes use of some of the code in R-a-y’s plugin. You can get it at http://www.buddyboss.com.

Viewing 25 results - 51 through 75 (of 129 total)
Skip to toolbar