Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'buddypress'

Viewing 25 results - 20,326 through 20,350 (of 69,127 total)
  • Author
    Search Results
  • #167175
    Hugo Ashmore
    Participant

    You don’t edit the dashboard BP pages, they are simply placeholders for BP, you mention the BP codex did you not see this page? :
    https://codex.buddypress.org/developer/theme-development/a-quick-look-at-1-7-theme-compatibility/

    That should help.

    #167171

    In reply to: Creating New Plugins

    modemlooper
    Moderator

    Mika and John were just pointing out you didn’t need to load that extra file to check for BuddyPress. The code you were using has been copy & pasted over the years from some early plugins.

    #167169
    crashy11
    Participant

    Yes that could work with shortcodes, but You need to put content every time you make post between that shortcode.

    #167168
    crashy11
    Participant

    I tried to put your code and changed user login but its not working.

    echo 'Username: ' . $current_user->user_login . "\n";

    echo 'User ID: ' . $current_user->ID . "\n";

    This situation could be done with custom post type, but another problem is that posts are not showing in category that you mark.

    I found on this forum someone had similar problem like mine:

    Posts are added to the activity stream when the post is saved.

    It’s done in the bp_blogs_record_post() function, which is hooked on to the save_post action.

    There isn’t any easy way to filter bp_blogs_record_post() to stop certain categories appearing, so, your best options may be:

    1. To unhook the whole bp_blogs_record_post() function and replace with your own
    or:
    2. Use a custom post type for your teaser posts – the built in function will only post to activity stream if the post type is ‘post’

    That questions and solution is from this link:
    https://buddypress.org/support/topic/resolved-filter-posts-with-specific-categorytag-from-activity-stream/

    If I go with solution 1. that was offered “unhook the whole bp_blogs_record_post() function and replace with your own”, where to find bp_blogs_record_post(), and just to delete it or?

    #167167
    mgrmn
    Participant

    See answer of @shanebp , or use the shortcodes, as explained http://www.s2member.com/kb/simple-shortcode-conditionals/

    #167165
    crashy11
    Participant

    Ok thank You I will try and let you know.

    What I am trying to accomplish is this. I created couple of categories by membership levels (1,2,3). I restricted those categories in S2 members options so only user that have certain level of membership can see posts in those category.

    Now problem is, when I create post for example for category level 3, everyone (all levels) can see that post in activity stream, that is what I am trying to remove. Posts don’t need to be in activity stream at all, or just to remove activity stream from account that I am making those posts.

    #167161
    @mercime
    Participant

    @disqusnow WP/BP versions? Theme used? Change to Twenty Twelve, is the issue resolved?

    #167159

    In reply to: Creating New Plugins

    modemlooper
    Moderator
    /*** Make sure BuddyPress is loaded ********************************/
    if ( class_exists( 'BuddyPress' ) ) {
    	add_action( 'bp_include', 'private_community_for_bp_lite_init' );
    } else {
    	add_action( 'admin_notices', 'private_community_for_bp_lite_install_buddypress_notice' );
    }
    
    function private_community_for_bp_lite_init() {
    	require( dirname( __FILE__ ) . '/private-community-for-bp-lite.php' );
    }
    
    function private_community_for_bp_lite_install_buddypress_notice() {
    	echo '<div id="message" class="error fade"><p style="line-height: 150%">';
    	_e('<strong>Private Community For BP Lite</strong></a> requires the BuddyPress plugin to work. Please <a href="https://buddypress.org/download">install BuddyPress</a> first, or <a href="plugins.php">deactivate Private Community For BP Lite</a>.');
    	echo '</p></div>';
    }
    #167157
    mgrmn
    Participant

    See this link http://www.s2member.com/kb/s2member-conditionals/ it explains how to get the conditionals using PHP, since I do not have s2 installed can’t get them for you

    Did some more reading for ya.

    try if (current_user_is("s2member_level1")) { echo "Woohaa got LEVEL 1" ; }

    and or echo S2MEMBER_CURRENT_USER_ACCESS_LEVEL;

    #167156
    mgrmn
    Participant

    To see the output of that, you can either put that in your theme/functions.php or i would say bp-custom.php in dir /plugins/pb-custom.php i saw that simular code of yours on stackoverflow.

    Not sure what you are tying to accomplish with that s2, but the issue is probably not that piece of code, but more trying to get the right levels.

    That code all it does, is checking usernames, so if username is “fred” it will remove the bp_core_record_activity but not according to levels. You need to figure out a way getting it to print out the levels. and then do a if or else statement per level.

    #167155

    In reply to: Create Group

    mgrmn
    Participant

    Not sure which file, however you should look in these directories look for div id subnav, it should be somewhere is my best guess for manual adding what you want.

    /bp-templates/bp-legacy/buddypress/groups || /bp-themes/bp-default/groups

    If you have it installed locally, I suggest you give that a try before editing online files.

    If you are using linux you can use a command like below to see which files have the subnavigation menu.

    sudo grep -lir “subnav” /var/www/wp-content/buddypress/
    or
    sudo grep -ir “subnav” /var/www/wp-content/buddypress/ (this will show you relevant code.

    If Windows, I suggest you use something simple like EditPlus open up all files, and use search function (If I remember correctly, check search all open files or something like that

    #167153

    In reply to: Creating New Plugins

    bp-help
    Participant

    @hnla @mercime @modemlooper
    I agree there needs sorting out and consistency in how to check for BP etc.
    I just got an email from Mika E one of the plugin reviewers and she says

    But … why?

    BuddyPress has loader actions you can hook into: https://plugins.trac.wordpress.org/browser/buddypress/trunk/bp-core/bp-core-actions.php#L34

    (I’m sitting next to JJJ right now and he pointed this out). So you don’t have to call loader.php, which is slower in the long run, and instead you hook into BP at the appropriate point.

    The whole thing it looks like you’re doing is adding this action:

    add_action( ‘admin_notices’, ‘private_community_for_bp_lite_install_buddypress_notice’ );

    And you want to only add that notice IF BuddyPress is loaded, right? So why not the smaller check? If you do that, you won’t have to call bp-loader, because you’re hooking in after it’s loaded.

    Why would I want my install buddypress notice to display if they have buddypress installed and the requirement for BP is met? That makes no sense. Right now it is setup to display only if someone using wordpress does not have BP installed and activated which is what it does and should do correct?
    I don’t get it! Any of you guys have advice?
    Thanks again!

    mik.e245
    Participant

    @mercime: Hmm, okay, I’ll post there. Thanks for the help!

    #167151
    @mercime
    Participant

    @nanaimomen The problem is more like the theme is using a proprietary templating system. BuddyPress works in nearly all WordPress themes. Regular WP tags like the_title() and the_content() should be in the theme’s page.php file for the BP Theme Compatibility magic to work, i.e., you no longer need to revise 16 template files manually like before.

    To resolve your issue, open up your theme’s page.php file and Save As > buddypress.php and ask the theme author to replace theme’s corresponding tags with the_title() and the_content(). Upload that updated buddypress.php file into your theme’s folder in server and you should be good to go.

    #167146
    @mercime
    Participant

    @forallatlantis Have you gone through basic troubleshooting like changing to Twenty Twelve theme and/or deactivating plugins batch by batch except BuddyPress to check what’s causing the issue?

    #167143

    In reply to: Create Group

    mgrmn
    Participant

    @dran2013 What you can do is this.

    FILES:
    /wp-content/plugins/buddypress/bp-templates/bp-legacy/buddypress/members/single/member-header.php
    /wp-content/plugins/buddypress/bp-templates/bp-legacy/buddypress/groups/single/group-header.php

    Add below <span class=”activity”><?php bp_last_activity( bp_displayed_user_id() ); ?></span>
    something like Create Group

    Enjoy

    @mercime
    Participant

    all content and users are mirrored/shared across the networks/sites


    @mike245
    Strange. Only users not the content should be shared across the network for that plugin as far as I know. Have only used the other BP Multinetwork plugin, so don’t quite know why that’s happening in your installation. Recommend that you post at plugin’s support forums https://wordpress.org/support/plugin/bp-multi-network

    #167140
    crashy11
    Participant

    Hey, can you please tell where I should place that code you posted?

    I am trying to exclude one username from activity stream since with that account I will make posts that are based on different membership levels. Or as I wrote on beginning just exclude all blog posts from activity stream.

    I tried to do it with custom post types, it doesn’t show up in activity stream, which is good, but posts are not showing in category they supposed to show. I read that it is also necessary to post some code somewhere for custom post type.

    mik.e245
    Participant

    @mercime Sorry, I forgot to mention that I’m already using BP Multi Network and Networks for WordPress! Unfortunately, they’re doing the wrong thing: while each network/site now has Buddypress working, all content and users are mirrored/shared across the networks/sites. Instead I need to have Buddypress working on all networks/sites, with *separate* content but *shared* users. Is there any way to do this?

    Thank you!
    Bill

    #167133

    In reply to: Create Group

    dran2013
    Participant

    I was wondering this too. The “create group” tab shows up if I directly go to my link: http://durhamregionactionnetwork.com/groups/ (same with Forums with bbpress) but how do users find the link when it isn’t appearing in their profile? I have everything enabled in settings for both plugins.So once a person is logged in they see this on their page:

    Activity
    Profile
    Messages
    Friends
    Groups
    Forums
    Events
    Settings

    But when you click on Groups from there, there is no link to create a group. Same with Forums. Maybe BuddyPress doesn’t have that option? I wanted to improve usability by adding the links to the user’s dashboard, it seems to make sense it would be there but it’s not. I hope I am explaining this OK 🙂 Thank you for any help you can provide!

    #167130

    In reply to: Creating New Plugins

    modemlooper
    Moderator

    It all depends on how the plugin functions. if you have WP options saved and then use bp_include to load plugin your settings won’t load fast enough for BuddyPress to use options.

    bp_include is used for code that accesses BuddyPress code. So you know that BuddyPress is loaded before you execute code. It should not be used to detect if BuddyPress is active.

    you can use https://codex.wordpress.org/Function_Reference/is_plugin_active

    or check if ( class_exists( ‘BuddyPress’ ) )

    #167129

    In reply to: Create Group

    @mercime
    Participant

    @mgrmn There should be a “Create a Group” button beside the page title in the Groups Directory page. https://codex.buddypress.org/user/buddypress-components-and-features/groups/#groups-directory

    If the “Create a Group” button doesn’t show up in your theme, that’s because the_title tag of page template is not within the WordPress loop. To resolve this issue, you can create your own link to the Create Groups page, just append /create to the URL of your groups directory page
    e.g.
    groups page -> http://example.com/groups
    groups create page -> http://example.com/groups/create

    Alternatively, if you prefer, you can instead add the patch to include the groups/create link in BP MyAccount section of the WP Toolbar https://buddypress.trac.wordpress.org/ticket/1838 – coming out in BP 1.8

    #167128
    mgrmn
    Participant

    Not sure, but I believe you need to add get_currentuserinfo(); for the part getting user info.

    Try something like this to debug and see if you get any reponse at all.

    function debug_userinfo() {
    	global $current_user;
          	get_currentuserinfo();
    	echo 'Username: ' . $current_user->user_login . "\n";
          	echo 'User email: ' . $current_user->user_email . "\n";
          	echo 'User first name: ' . $current_user->user_firstname . "\n";
          	echo 'User last name: ' . $current_user->user_lastname . "\n";
          	echo 'User display name: ' . $current_user->display_name . "\n";
          	echo 'User ID: ' . $current_user->ID . "\n";
    }

    See wp codex https://codex.wordpress.org/Function_Reference/get_currentuserinfo

    @mercime
    Participant

    @mike245 by default, there’s only one instance of BuddyPress per WordPress (single or multisite) installation. What you want – multiple BuddyPress installations in one Multisite install – is not possible without a BP multinetwork plugin. There are two plugins available and of those two, since you want a shared userbase, you would need https://wordpress.org/plugins/bp-multi-network/

    #167126

    In reply to: Create Group

    mgrmn
    Participant

    Yes, they are all checked / enabled

    BuddyPress -> Components & BuddyPress -> Settings

    Can not add groups, not as Admin , Not as User. Neither can I as Admin via Admin panel Groups.
    Only direct insert DB

Viewing 25 results - 20,326 through 20,350 (of 69,127 total)
Skip to toolbar