Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'buddypress'

Viewing 25 results - 14,351 through 14,375 (of 94,562 total)
  • Author
    Search Results
  • nickrobinson352
    Participant

    I created dynamic menus to the Buddy Press groups using the following code

    `$url = site_url().”/groups/”.$groupslug;’

    The $url variable has the correct variable, but while clicking from there, wordpress switches to the intended group, but I get a warning that says –
    “Notice: bp_nav was called incorrectly. These globals should not be used directly and are deprecated. Please use the BuddyPress nav functions instead. Please see Debugging in WordPress for more information. (This message was added in version 2.6.0.) in /home/…/functions.php on line 3897”

    I dont get the same warning when I click through the normal buddpress pages.

    #256503
    phucitol
    Participant

    Thanks so much for your quick responses. I’m not explaining myself well I guess.

    I want my users to only see and use the visual editor. I know that the button to submit is on the page. I know it is being hidden by javascript on page load. I know that it normally becomes visible when clicking in the textarea. The text area in the visual editor, located in an iframe, doesn’t register the events that make the submit button visible.

    Do you know if it is possible to get the buddypress javascript that handles the buttons visibility to work with the text area in the iframe?

    Alternatively, would it be possible for me to write custom buttons and add them to the default BP textarea?

    #256498
    danbp
    Participant

    I use that function bpfr_custom_group_default_tab and it works.
    Have you replaced the group slug to yours in ‘case’ ? This must fit the exact slug, the one you see by mouse over the group name in the bottom left corner of your brower (and normally in the browser’s address bar).

    Please ask one question at a time. Make an effort to be clear. It’s difficult to follow your post !

    – I want to do this on profile: details, item names…

    – I want to do this on groups: details, item names…

    NB 1: if you want to change the landing tab for ALL groups, you can use:

    
    define( 'BP_GROUPS_DEFAULT_EXTENSION', 'members' );

    With this, all groups will use the group members directory as landing tab instead the group activity.
    If you want a different landing tab for each group, use the snippet and don’t use define.

    Changing Internal Configuration Settings

    NB 2: the tab name has no influence on the landing tab. The name and the slug are handled separately, precisely because of that

    NB 3: where you put functions in bp-custom has no importance.

    #256495
    socialc
    Participant

    I’m building a theme and found that bp_is_user_forums() doesn’t return true and the related template is never loaded. Meaning that my-theme/buddypress/members/single/forums.php and /forums are redundant.

    Also, my-theme/buddypress/members/single/plugins.php is the file being used to render user replies, topics, subscriptions and favorites.

    This is a bit of a problem, as I need control over the markup here.

    So my question is, are there any template tags to pick up on BBPress forums at profile level and serve custom templates? If so, could you please show me how. I’m sorta stuck.

    #256492
    danbp
    Participant
    #256491
    daniervelin
    Participant

    Olá! Estou tendo o seguinte problema no meu site (http://realptl.portugueslivre.org/realptl/) com o Buddypress: ao clicar sobre a página “membros” ou “atividade”, abrem normalmente. No entanto, logo depois, quando clico sobre outra página, aparece o mesmo link da página “membro” ou da página “atividade” e não a página solicitada. Por que isso acontece e como resolver?
    Obrigada!

    #256490
    danbp
    Participant

    The Home tab is the default one. If you remove that tab, BP has no way to know where to output the other group tabs content. If you remove Home(aka activity) you should define another landing tab.

    But when you want to modify groups, you shouldn’t define ‘profile’, but ‘groups’. (read what you wrote!)
    For the profile landing tab, see this codex page.

    For groups, you can try this snippet. This let you define a different landing tab for each of your groups (not profile, ok ?). 😉

    function bpfr_custom_group_default_tab($default_tab){
    	/**
    	 * class_exists() is recommanded to avoid problems during updates 
    	 * or when Groups Component is deactivated
    	 */
    	if ( class_exists( 'BP_Group_Extension' ) ) : // 
    	
    	$group=groups_get_current_group();//get the current group
    	
    	if(empty($group))
    	return $default_tab;
    	
    	switch($group->slug){
    		
    		case 'kill-bill': // group name (use slug format)
    		$default_tab='forum';
    		break;
    		
    		case 'groupe-2014':
    		$default_tab='members';
    		break;
    		
    		default:		
    		$default_tab='home';// the original default landing tab
    		break;
    		
    	}
    	
    	return $default_tab;
    	
    	endif; // end if ( class_exists( 'BP_Group_Extension' ) )
    }
    add_filter('bp_groups_default_extension','bpfr_custom_group_default_tab');
    #256489
    danbp
    Participant

    Global.js is related to BP Default theme which is no more used since 1.9.
    The “new” js you can check for comment count is \buddypress\bp-templates\bp-legacy\js\buddypress.js:667

    I don’t know how the default 5 count is set before firing Show all X comments link. But i haven’t read very attentively the whole js file.

    If your goal is to gain some place on activity feeds, you may use a show/hide comment button ?

    function add_comment_hide_show() {
    ?>
    <style>
    .single-group .activity-comments ul{display: none;}
    </style>
    <script type="text/javascript">
    jQuery(function($) {
    	setInterval(function() {
    		$('.activity-meta').each(function() {
    			if( !$(this).find('.show-comments').length ){
    				var html = '<a href="#" class="button bp-primary-action show-comments">Show/Hide Comments</a>';
    				$(this).find('.button.acomment-reply').after(html);
    			}
    		});
    		
    	}, 500);
    	
    	$('body').on('click', '.show-comments', function(e) {
    		e.preventDefault();
    		var obj = $(this).closest('.activity-content').next('.activity-comments').find('ul');
    		obj.slideToggle();
    		return false;
    	});
    	
    });
    </script>
    <?php
    }
    add_action( 'wp_footer', 'add_comment_hide_show' );

    Or if you want to limit the number of comment a member can leave on activities, BPDEVEL has a premium plugin called BP Rate Limit User Activity which can do that.

    On Trac, some very old tickets about comments: #2768, #1870

    Perhaps @dcavins can tell you more about this ?

    #256488
    marcono
    Participant

    ‘danbp’ your codes work great!
    One thing, though, since I removed the ‘home’ item in groups, now if I create a private group or click on a public group icon, the group page will not be available!
    I think it is because the ‘home’ item has remained as the default page for the group pages!? I changed my profile default page with ‘define(‘BP_DEFAULT_COMPONENT’, ‘profile’ );’ but it seems for changing group default tab story is different, so I used code suggested here: https://buddypress.org/support/topic/changing-group-tab-display-defaults/

    But still no success!?

    fidelduque
    Participant

    Hi, I’m using Buddypress Version 2.5.3 and WordPress 4.5.2.

    I’m running a multisite wordpress installation, Right now I’m trying to exclude the suscribers in the members directory, this is the code i found:

    function bpdev_exclude_users($qs=false,$object=false){
        //list of users to exclude
         
        if($object!='members')//hide for members only
            return $qs;
            
        $excluded_user = implode(',',get_users('role=subscriber&fields=ID'));
        $excluded_admins = implode(',',get_users('role=administrator&fields=ID'));
        //$excluded_self=bp_loggedin_user_id();
    	
        
        $args=wp_parse_args($qs);
        
        //check if we are searching for friends list etc?, do not exclude in this case
        if(!empty($args['user_id']))
            return $qs;
        
        if(!empty($args['exclude'])){		
            $args['exclude']=$args['exclude'].','.$excluded_user;
            $args['exclude']=$args['exclude'].','.$excluded_admins;
            //$args['exclude']=$args['exclude'].','.$excluded_self;
        } else {
            $args['exclude']=$excluded_user;		
    		if(!empty($args['exclude']))
    			$args['exclude']= $args['exclude'].','.$excluded_admins;
    		else
    			$args['exclude']=$excluded_admins;
            //$args['exclude']=$excluded_self;
        }
        $qs=build_query($args);
       
       return $qs;  
    }
    add_action('bp_ajax_querystring','bpdev_exclude_users',20,2);

    but right now, the get_users function won’t show any subscriber because there are not suscribers on this site, but on the other ones. Anyway, the buddypress is showing all users including the ones in the other sites.

    any hint?

    Thanks

    David Cavins
    Keymaster

    Hi there-

    Yes, 2.6.1 (and 2.6.1.1) have a conflict with BP Group Hierarchy. The problem is caused by the addition of the autoloader check in bp-loader.php because BPGH instantiates its class before BP knows if the groups component is active or not. The short term fix is, unhappily, to change bp-loader.php. Comment out the line that reads return (add a // before return) here:
    https://github.com/buddypress/BuddyPress/blob/master/src/bp-loader.php#L621

    allancaeg
    Participant

    On the profile page, the count of messages, notifications, etc are displayed:
    https://mercime.files.wordpress.com/2015/03/bpmenu-frontlinks.jpg

    Same goes for the BuddyPress header:

    View post on imgur.com

    BuddyPress has this menu feature:

    BuddyPress Links in WordPress Menus

    How do I add the notification count beside the menu item on the header navigation?

    allancaeg
    Participant

    There are now BuddyPress links for WordPress menus: https://codex.buddypress.org/getting-started/buddypress-links-in-wordpress-menus/

    How do I display the user avatar photo, though? BuddyPress forum itself does it, but I think it’s a slighly different approach as its the WP admin bar:

    View post on imgur.com

    But that’s the effect I’m going for, for my main header menu.

    The BuddyBoss theme exhibits this nicely with their user profile dropdown menu:

    View post on imgur.com

    How do I display the photo alongside the profile menu link?

    #256461
    graeme_bryson
    Participant

    I’m currently trying to bring the number of comments shown below a post from 5 to 2. I’ve updated the following lines in ‘global.js’, but the feed still outputs 5 comments below each activity item.

    (global.js line 1490)
    if ( jq(this).children('ul').children('li').length < 5 ) return;
    to
    if ( jq(this).children('ul').children('li').length < 2 ) return;

    (global.js line 1502)
    if ( i < comment_lis.length - 5 ) {
    to
    if ( i < comment_lis.length - 2 ) {

    I’m running a vanilla install of BuddyPress 2.6.1.1 on WP 4.5.3, so I’m assuming my logic is incorrect in how I’m trying to bring the comment count down. Any help would be massively appreciated as I’ve hit a bit of a brick wall.

    Cheers, Graeme

    #256458
    allancaeg
    Participant

    Some themes are designed for BuddyPress. They have app-like header menus like what you’ll find on Facebook, Twitter, Quora, ProductHunt, etc.

    What are the typical features of such header menus?
    – AJAX search
    – live notifications
    – profile dropdown

    That’s a standard formula formula for web apps these days: http://imgur.com/10lKZnK . In one bar: you have the logo, an AJAX search, a notification dropdown with an unread counter, and user profile dropdown.

    This forum has 2 of them integrated with the menu, while BuddyPress on default WordPress websites adds this to the wp-admin bar on top.

    Some themes display these very well:
    – http://imgur.com/zqw5kRd
    – http://imgur.com/XJihK17

    How do I get this effect on any custom theme? Are there plugins for these search, notification, and profile features?

    Bj123
    Participant

    After the BP 2.6 update(s) I still can’t getting the BP Group Hierarchy plugin to work again on my Boss theme. Even with the recommended fix (https://github.com/ddean4040/BP-Group-Hierarchy/pull/21/files) I am still getting the fatal error:

    Fatal error: Class ‘BP_Groups_Component’ not found in [….]/wp-content/plugins/bp-group-hierarchy/bp-group-hierarchy-loader.php on line 6

    Anyone know what the problem could be? – Some others seem to have a similar problem:
    https://wordpress.org/support/topic/breaks-boss-theme-with-buddypress-261

    WP 2.5.3/BP 2.6.1.1/Boss 2.2.1

    #256456

    In reply to: Members display name

    webexpression
    Participant

    Ahh yes I see. I’m not entirely sure. Apparently what I am in need of changing is code from BuddyPress.

    Does anyone know another way to get a problem fixed if you don’t get a response on here? I really need help.. oh and on my website also 😉

    #256453
    danbp
    Participant

    No, not for the moment. We’re handling here about profile and group nav, not about Group or Member Directory nav.

    If you have a snippet who works for the Directory, feel free to add it to the Nav Api examples. Codex Contributors are always welcome.

    #256451
    danbp
    Participant

    @socialc, since 2.6 and the new Nav API, there is a much simplier possibility as the translation file to change nav item names.

    @marcono, try this; not sure you learned, below snippet is on Nav API examples i indicated previously. 😉

    function bpcodex_rename_group_tabs() {
    
        if ( ! bp_is_group() ) {
            return;
        }
       
        buddypress()->groups->nav->edit_nav( array( 'name' => __( 'Group Discussion', 'buddypress' ) ), 'forum', bp_current_item() );
    }
    add_action( 'bp_actions', 'bpcodex_rename_group_tabs' );
    
    function bpcodex_rename_profile_tabs() {
     
          buddypress()->members->nav->edit_nav( array( 'name' => __( 'My Buddy Forums', 'textdomain' ) ), 'forums' );
          buddypress()->members->nav->edit_nav( array( 'name' => __( 'My Buddy Groups', 'textdomain' ) ), 'groups' );
     
    }
    add_action( 'bp_actions', 'bpcodex_rename_profile_tabs' );
    #256450
    socialc
    Participant

    @marcono you might want to read this page and consider making a translation file of your own.

    danbp
    Participant

    Make sure you have pretty permalinks enabled on your WordPress install. (whatever except default) and save.

    And check your install again.
    Ray’s script is not a bug tracker, it gives only information about global variables which is usefull when you want to debug a custom script. If you seek for bugs – rarely the case on a new install -, activate wp_debug in wp-config.php

    https://codex.wordpress.org/Debugging_in_WordPress

    Configure BuddyPress

    tutorbe
    Participant

    Dear All,

    I hope someone can point me a clue regarding the following:

    I have just installed WP 4.5.3 along with only Buddypress 2.6.1.1 activated, when I tried to access members/admin/profile/, it just returned 404 page. I have tried with different themes, the same issue still existing.

    I tried to investigated the problem using the debug script from r-a-y, it just showed:

    Array
    (
        [component] => profile
    )

    Thanks and best regards,

    Jobi

    DrHariri
    Participant

    Hi,

    I was working on an updated theme for my blog on my staging server (WPEngine) but when I moved all files & DB to the production install, the slug for any Buddypress menu link I add changed from being:
    http://educadme.staging.wpengine.com/members/admin/groups/
    To
    http://educad.me/somaia-hosam-triggered-wp_login-1x/admin/groups/

    The “somaia-hosam-triggered-wp_login-1x” slug seems to be for an achievement custom post of BadgeOS.Tried disabling BadgeOS without success.

    I’ve read somewhere that a similar issue existed in some of the older versions where urls are leading to 404 errors but not sure if it is related.

    Anyone had a similar issue?

    Thanks!

    #256432

    In reply to: Custom post type

    jaaahaaa
    Participant

    Solved!!

    What I was testing was tracking comments. I realized that it worked by using the tutorial for tracking when new objects are created.

    However, comments did not work so I ended up editing the creation of the custom post type. Posting the full code here if anyone else googles ignitiondeck buddypress integration:

    ignitiondeck-admin.php line 5 to 46:

    add_action( 'init', 'ign_create_post_type' );
    function ign_create_post_type() {
    	require 'languages/text_variables.php';
    	$slug = apply_filters('idcf_archive_slug', __('projects', 'ignitiondeck'));
    	register_post_type( 'ignition_product',
    		array(
    			'labels' => array(
    				'name' => $tr_Projects,
    				'singular_name' => $tr_Project,
    				'add_new' => $tr_Add_New_Project,
    				'add_new_item' => $tr_Add_New_Project,
    				'edit' => $tr_Edit,
    				'edit_item' => $tr_Edit_Project,
    				'new_item' => $tr_New_Project,
    				'view' => $tr_View_Project,
    				'view_item' => $tr_View_Project,
    				'search_items' =>$tr_Search_Project,
    				'not_found' => $tr_No_Products_found ,
    				'not_found_in_trash' => $tr_No_Product_in_Trash,
    				'all_items' => __( 'All Videos' ),
    			),
                'public' => true,
    			'show_in_nav_menus' => true,
    			'show_ui' => true,
    			'publicly_queryable' => true,
    			'exclude_from_search' => false,
    			'hierarchical' => apply_filters('idcf_hierarchical', false),
    			'menu_position' => 5,
    			'capability_type' => 'post',
    			'menu_icon' => plugins_url( '/images/ignitiondeck-menu.png', __FILE__ ),
    			'query_var' => true,
    			'rewrite' => apply_filters('id_register_project_post_rewrite', array('slug' => $slug, 'with_front' => true)),
    			'has_archive' => apply_filters('id_register_project_post_has_archive', $slug),
    			'supports' => array( 'title', 'author', 'editor', 'thumbnail', 'revisions', 'comments', 'buddypress-activity' ),
    			'taxonomies' => array('category', 'post_tag', 'project_category'),
    			'bp_activity' => array(
    			    'action_id'         => 'new_ignition_product',
    			    'comment_action_id' => 'new_ignition_product_comment',
    			)
    		)
    	);
    }
    #256431
    socialc
    Participant

    … or just add a login link to your site anywhere in your theme files. e.g <a href="<?php echo wp_login_url(bp_loggedin_user_domain()); ?>"><?php _e('Login', 'buddypress'); ?></a>.

    This will redirect a user to their profile page after logging in.

Viewing 25 results - 14,351 through 14,375 (of 94,562 total)
Skip to toolbar