Skip to:
Content
Pages
Categories
Search
Top
Bottom

Search Results for 'change buddypress menu'

Viewing 25 results - 376 through 400 (of 515 total)
  • Author
    Search Results
  • #105672
    aces
    Participant

    Hopefully the following link might help? https://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/add-a-welcome-message-to-admin-bar-instead-of-website-name/#post-87017 ?

    I use a version of it though the admin menu bar is only seen by those logged in….

    #105026

    In reply to: hiding dashboard

    David Carson
    Participant

    Look for the `bp_adminbar_thisblog_menu` function in `bp-core/bp-core-adminbar.php`. It’s around line 151 (BP Version 1.2.7).

    There is an `if` statement with `current_user_can( ‘edit_posts’ )`. Replace `edit_posts` with whatever role you want to check it for. https://codex.wordpress.org/Roles_and_Capabilities

    And you might already know this, but you should try to make your changes to the function using `bp-custom.php`. https://codex.buddypress.org/extending-buddypress/bp-custom-php/

    #104447
    bopyd
    Member

    I am having a similar issue. The menu bar link shows
    http://siteURL/press/members/admin/activity/ which gives me an error. If I change it to
    http://siteURL/press/index.php/members/admin/activity/ Then it works fine.
    I am on Windows hosting IIS 6.0.

    Any suggestions?

    #104059
    @mercime
    Participant

    === Do I need to make any changes to my bb-config.php file to run multisite? ===

    Just to be clear, you had a single WP install with BuddyPress and created internal bbPress forums i.e. via BuddyPress forums set up, before upgrading to WP 3.0.4 and then creating a network/going multisite? Try to re-run Forum Setup. Backup database and server files, then go to dashboard > BuddyPress menu > Forums Setup > Use an existing bbPress installation – and in next panel point to your bb-config.php then click on “Complete Installation”

    zkwc
    Participant

    That happened to me once. I know that I had to change back to admin. But I don’t remember the steps as it was over a year ago with the old buddy.

    #102464
    Hugo Ashmore
    Participant

    You are using a custom theme as soon as you do that you enter a new realm and need to know what you are doing, this particular theme Suffusion uses a custom menu of some description and BP directory menu items will not be included by default. BP hard codes these menus links in header.php (soon to change to WP nav menus)

    You! have to do a little manual work in getting things to work and need to understand how both Suffusion and BP work, this act of trying to get BP to use any old WP theme is not a natural one.

    In all honesty you have simply asked this question in entirely the wrong place – and perhaps I should have said this much earlier – The correct place to have addressed these issues would have been to the theme home, Suffusion has it’s own support and if you had asked there would probably have had this wrapped up and solved in no time. Strictly speaking this site supports BP and BP default theme it can’t be expected to support digressions and third party implementations – other than the plugins that have a group support home on the site.

    I looked through suffusion support for you and quickly got an impression of what may be wrong however this is not something I ought to be doing for anyone :)

    http://www.aquoid.com/forum/search.php?st=0&sk=t&sd=d&sr=posts&keywords=buddypress

    #101477
    Boone Gorges
    Keymaster

    I also have found myself torn about using pages for BP directories. In the end, though, I think it’s a compromise that works out for the better in the short- to medium-run, and does not have awful long-term consequences.

    In my view, it is a gross overstatement to say that this move ‘ruins’ BP. However, there are a few things about it that are unappealing:
    1) It forces the creation of what are, essentially, dummy pages – whatever content you might add to the page through the normal WP editor is totally ignored
    2) Related – It uses part of the WP page infrastructure (URLs) without using others (in particular, WP page templates)

    Problem (1) is unappealing, but it is mitigated by a couple of points. First, the current system is not a whole lot better. Instead of having ‘dummy’ pages that you can see in the admin (like BP trunk has), the current version of BP has ‘phantom’ pages, so that when BP detects a URL like example.com/groups, it essentially hijacks the page load in order to do its own stuff. This is a bit jarring, and not at all transparent. So there is a trade-off, but it’s not all bad. Second, while the idea that ‘Pages in WordPress are supposed to be static content’ seems right to me in broad strokes, it doesn’t seem to me to be a hard-and-fast rule. Many plugins (gallery plugins, ecommerce plugins, etc) display their content by means of a shortcode that is manually inserted on a page or post, with pages being used for their pretty URLs.

    On the other hand, there are some real benefits to directories-as-pages:
    A) Easier URLs (as @driz has noted)
    B) Integration into WP 3.0-type menus (this is the big one IMO)

    How important are things like (A) and (B)? For sites maintained by folks with some PHP chops (and organizations with money to pay people with PHP chops), they could be fairly easily accomplished with BP_GROUPS_SLUG, etc, and with some other finagling. But – and this is just a guess – this profile does not match most of the users of BP. Nor should it, necessarily. To the extent that BP can be easy to use and install for people with little technical knowledge, without at the same time making it less flexible from a developer’s point of view, it should be. This change is good for end users, and is no more difficult for developers than the current technique, so it seems like a net win.

    Another more theoretical argument for the directories-as-pages move (especially as compared to the new admin panel @driz suggests for changing slugs) is that BP shouldn’t reproduce functionality that WP could provide, unless there is a convincing reason for doing so. Using WP pages for BP directories is a step toward greater BP-WP integration. It’s not perfect (see my problem (2) above) but it is a start.

    As for custom post types: It’s likely that at least some of BP’s components will be refactored to use custom post types in the future. When that happens, part of the upgrade script will probably involve removing the dummy pages at issue here. So from the user’s point of view, the transition will be seamless.

    I should say that I am in agreement with a lot of the sentiment in this thread about making BP a bit more lightweight, framework-y, and disjointed than the sometimes hulking behemoth it is now. However, that kind of transition can and probably should be gradual (at least more gradual than the 1.3 release).

    alcoon
    Member

    Is there an update for this fix? 1.2.7 broke this solution on our site and I can’t find an alternative so far.

    Really, it’s extremely annoying that BuddyPress keeps making changes to the themes in minor updates. Every update (1.2.7 also saw us gain an unwanted admin bar menu item with links to the WordPress backend) sees us having to chase down the little changes they made which break our layout.

    #100495
    r-a-y
    Keymaster

    No need to bump the topic multiple times.

    If you are not sure how to patch and you feel a little adventurous, make the changes manually:
    https://trac.buddypress.org/attachment/ticket/2661/2661.002.patch

    If you have access to edit plugins, login to your WP dashboard and navigate to “Plugins > Editor” and select BuddyPress in the dropdown menu located near the top right corner, then edit the files mentioned in the patch.

    Otherwise, open up your FTP program and make the edits mentioned in the patch.

    **Be sure to make a backup of the files you are attempting to edit before you make any changes**

    Green lines mean they are code additions; red lines mean delete.

    #98885
    imjscn
    Participant

    @r-a-y , in my child them header.php, I removed all bp nav menus already. I use custom menu in widget. So, there’s no way to figure out where the slugs comes from.
    my buddypress is running on root blog, network activated, but not enable bp functions on multisite.
    The permarlinks are correct, only the browser tabs shows inproper site name. for example, if you create a sub–blog under buddypress, and open the page “About”, the browser tab shows “BuddyPress.org | About” , I prefer it shows “other blog | About”
    Where can I go to edit this?

    #98403
    David Lewis
    Participant

    How to make it work with WordPress Single Blog:

    Step 1
    —-
    Go into the plugin folder and open the bp-auto-group-join.php file. Line 67 should be:
    `add_submenu_page( ‘wpmu-admin.php’, __(“Link Auto Join Groups”, ‘buddypress’), __(“Auto Join Groups”, ‘buddypress’), 1, __FILE__, “auto_group_join_plugin_options” );`

    change it to this:
    `add_submenu_page( ‘options-general.php’, __(“Link Auto Join Groups”, ‘buddypress’), __(“Auto Join Groups”, ‘buddypress’), 1, __FILE__, “auto_group_join_plugin_options” );`

    That first argument just tells the action hook `add_submenu_page()` where your plugin menu item should go based on page slug. The options-general.php slug corresponds to the “Settings” menu. So you’ll get a link for the plugin settings under the Settings menu. I couldn’t figure out how to add the link to the BuddyPress menu since that menu works a little differently.

    Step 2
    —-
    Go to line 147:
    `add_action( ‘wpmu_new_user’, ‘update_auto_join_status’, 12, 2);`

    Add add this new line below it:
    `add_action( ‘user_register’, ‘update_auto_join_status’, 12, 2);`

    I figured the wpmu_new_user action hook wouldn’t work with single WP. I was right. I tested with the additional user_register hook and it works. Joy

    #97671
    Hugo Ashmore
    Participant

    @DJPaul what are you after Paul? I think everyone might be a little lost as to what actually needs doing? is it just the styles that need sorting, As for my earlier question regarding changes to nav menus for 3.1 and as much as it may be irrelevant? I managed to track down a ticket correcting the issue of not being able to remove parent ul elements which is helpful but couldn’t spot anything dealing with child pages and nesting thereof

    #97460
    Paul Wong-Gibbs
    Keymaster

    @modemlooper the cause for custom link nav items not getting the style for the “selected” page is as a result of _wp_menu_item_classes_by_context() in WP Core, which is doing what it’s meant to do.

    There’s no good hooks or filters we can use. We’re going to need to style ul#nav li.current-menu-item the same as ul#nav li.current_page_item. We can change the selector on line 150 of the CSS file. Anyone see any problems with styling current-menu-item?

    #97403
    modemlooper
    Moderator

    No biggie for the IE6 display:none bug. I changed it per @hnla‘s suggestion.

    @djpaul an issue: when creating a menu link thats not a page just a straight url link to say /activity it doesn’t add the class to make the tab look selected.

    check it by clicking activity and then another tab http://tempsg.com/

    #96469
    emailaya
    Member

    seems like all my links in the blog are broken
    http://www.emailaya.com/blog/
    on any click i get that the url does not exists on the server, for example:
    /blog/members/admin/
    or when i hover a post title, the url is: http://www.emailaya.com/blog/http:/www.emailaya.com/blog

    the same happens when i choose an option in my account/notifications at the top menu.
    also i didnt find where can i change the settings for buddypress

    thanks

    #95499

    In reply to: how to edit menus?

    @mercime
    Participant

    The navigation menu is in the header.php starting here https://trac.buddypress.org/browser/tags/1.2.5.2/bp-themes/bp-default/header.php#L46
    You can change the links by creating a Child Theme so your revisions won’t be overwritten when BP is upgraded.
    You won’t find the BP menus in the Appearance > Menu unless you revise the links in navigation menu an code navigation menus function in your theme’s functions.php file and add the template tag for that in header.php – https://codex.wordpress.org/Navigation_Menus
    You can also try out this plugin – https://buddypress.org/community/groups/add-all-nav-links-to-bp-adminbar/home/

    #95091

    Alright, concrete feedback now that I’ve played with your features.
    1) Header image is too small. I would like options to have a larger image. I like 275 px
    2) Remove the search from the header. I’d like options to remove that. It’s unneeded for my site.
    3) Title. It’s currently behind the gray bar for the buddypress. Move it down?

    Now, I’m just learning PHP, been using HTML for years. New to WordPress in last year. Can I make the above changes somehow in the style.php? I hate to make changes and break it.

    I like that it uses the custom menus, so much of my information needs to be accessed in it’s categories.

    Thanx for the hard work!

    #94339
    Bowe
    Participant

    @skolbloggense: BP-Slick uses the same BuddyPress translation strings so the theme should just work fine with your Translation. The only thing that is not yet translated is the menu navigation. But that can all be found in one file, which is organized and very easy to edit. I think it will take you about 10 mins to translate it!

    I will add po/mo files to the theme pretty soon (to make upgrading easier, so you won’t lose changes) but right now it’s yet added :) The Theme is now for sale btw.. It can be purchased with 20% discount until the end of the week: http://bp-tricks.com/purchase-bp-slick/.

    Here’s the sales page with it’s features: http://bp-tricks.com/pre-order-bp-slick/. And a short video on how to get it running: http://www.youtube.com/watch?v=gMb7tXXV6Rw&feature=player_embedded

    #93915
    rayd8
    Member

    I’m going to try and add the steps for the fix again. I didn’t see the note about using backticks for code…

    1. Open the index.php, save it to your theme as posts-page.php (or whatever template name you like).
    2. Edit the newly created posts-page.php file and place the following at the top to create a page template:

    `<?php
    /*
    Template Name: Posts Page
    */
    ?> `

    3. Now scroll down in the posts-page.php to the beginning of the WordPress loop and just before the line “ add this one line of code “ Note: (5 == the number of post to show you can change this to whatever you want.)
    4. Save the posts-page.php file.
    5. In your WordPress/BuddyPress admin panel create a new page called “Blog” (or something similar) and select “Posts Page” under Template.
    6. Publish page.

    You should now be able to go to your Settings -> Reading menu and set a static page and select your Posts Page to show your blog posts.

    #93027
    phos flip
    Participant

    Don’t know if this is any use to anyone and no doubt there are far better ways of doing it but just in case it is of use….

    I’ve created (hacked really) a plugin made up of 3 files, one of which is useless for now but at a future point I’d like to play around with it.

    bp-group-catdisp.php

    `<?php
    /*
    Plugin Name: Display Categories
    Plugin URI:
    Description: Displays a blog category in groups
    Author: Mas
    Version: 0.1
    License: GNU General Public License 2.0 (GPL) http://www.gnu.org/licenses/gpl.html
    Site Wide Only: true
    */
    if ( !defined( ‘BP_GROUP_CATDISP’ ) )
    define ( ‘BP_GROUP_CATDISP’, ‘programme’ );

    function bp_group_catdisp_init() {
    bp_group_catdisp_wrapper();
    }

    if ( defined( ‘BP_VERSION’ ) )
    bp_group_catdisp_wrapper();
    else
    add_action( ‘bp_init’, ‘bp_group_catdisp_init’ );
    //above links to admin screen in backend
    require(dirname(__FILE__) . “/bp-group-catdisp-admin.php”);

    // group options
    function bp_group_catdisp_wrapper() {
    class bp_group_catdisp extends BP_Group_Extension {
    var $visibility = ‘private’;

    var $enable_create_step = false;
    var $enable_edit_item = false;
    var $has_caps = false;

    function bp_group_catdisp () {
    global $groups_template;

    // group title

    $this->name = __( ‘Programme’, ‘programe’ );
    $this->slug = BP_GROUP_CATDISP;
    $this->nav_item_position = 12;
    $this->create_step_position = 12;

    // group ID for displaying category within
    global $bp;

    $group_array = array( 17,11 );

    if ( in_array( $bp->groups->current_group->id, $group_array) )
    //group ID to display in array. Note can reverse this code ie. set it not to display in listed groups by placing !in_array( $bp etc.

    {
    $this->enable_nav_item = true;
    } else {
    $this->enable_nav_item = false;
    }

    }

    function display () {
    global $bp, $groups_template;

    include(“bp-group-catdisp-edit.php”);

    //bit above links to file that prints to tab

    }

    }
    bp_register_group_extension( ‘bp_group_catdisp’ );
    }

    ?>
    `

    bp-group-catdisp-edit.php

    `

    stories4change Y-Care Programme

    Information and modules related to the Y-Care Programme 2010/11

    <a href="” rel=”bookmark” title=”Permanent Link to “>

    Sorry, no posts matched your criteria.

    `

    bp-group-catdisp-admin.php

    `<?php

    function group_catdisp_add_admin_menu() {
    add_submenu_page( ‘bp-general-settings’, __( ‘Group Categories’, ‘bp_group_catdisp’ ), __( ‘Disp Cats’, ‘bp_group_catdisp’ ), ‘manage_options’, __FILE__, ‘group_catdisp_plugin_options’ );
    }
    add_action(‘admin_menu’, ‘group_catdisp_add_admin_menu’, 15);

    function group_catdisp_plugin_options() {
    if (!current_user_can(‘manage_options’)) {
    wp_die( __(‘You do not have sufficient permissions to access this page.’) );
    }
    $updated = false;
    //above this is php for creating admin page and below is printed onto admin page

    ?>

    <?php
    if ( !$options = get_option( ‘bp_gm_settings’ ) )
    $per_page = 10;
    else
    $per_page = $options;

    $args = array( ‘type’ => ‘alphabetical’, ‘per_page’ => $per_page );

    if ( $_GET == ‘name’ )
    $args = ‘alphabetical’;
    else if ( $_GET == ‘group_id’ )
    $args = ‘newest’;
    else if ( $_GET == ‘popular’ )
    $args = ‘popular’;

    if ( $_GET )
    $args = $_GET;
    else
    $args = 1;

    if( bp_has_groups( $args ) ) :
    global $groups_template;
    ?>

    <?php
    if ( !$group )
    $group =& $groups_template->group;
    ?>

    Category

    Categories

    You don’t have any groups to manage.

    <?php
    }
    ?>
    `

    The first two hard code a group by ID and display a selected wordpress category within that group. The last file is the useless one. I’d started hacking from one of @boonebgorges plugins with the idea of creating an admin screen from which groups could be linked to blog categories.

    I’ve run out of time for now to play with that further and so for now am just going to duplicate the first two files for another couple of groups which will work for my purposes.

    #92526
    Paul Wong-Gibbs
    Keymaster

    This site uses a customised version of the current “trunk” code, which adds support to BuddyPress to integrate into WordPress’ pages system/menus properly.

    mariochampion
    Participant

    just to add to this discussion, concerning what hook to link it to…this is what works for me. i didnt have luck with bp_setup_nav for some reason. i dont recall where i got this example, but think its bp-xprofile.php itself. this worked in both theme>functions.php and in my own mmc_functions.php which i “require()” in functions.php

    just to add a hint of background, we are moving these two items to the ‘settings’ tab from the profile tab. the removing is trivial, the adding is trivial, the getting all the right functions/themes/forms called, not so much. but its done and it works.

    here is the code for removing sub-tabs — aka options:

    `
    //removes in a structural way.. no change to bp-xprofile.php

    function mmc_bpsetupnav_removefromprofile(){
    global $bp;

    if ( $bp->current_component == $bp->profile->slug ) {
    bp_core_remove_subnav_item($bp->profile->slug, ‘edit’);
    bp_core_remove_subnav_item($bp->profile->slug, ‘change-avatar’);

    }//end if
    }//end function
    add_action( ‘wp’, ‘mmc_bpsetupnav_removefromprofile’, 2 );
    `

    here is my code for adding them to the settings tab

    `
    ////////////////////////////////////////////////////////////
    ////// functions for moving to Settings tab the editprofile/change avatar sub-tabs

    function mmc_bpsetupnav_forsettings(){
    global $bp;

    if ( $bp->current_component == $bp->settings->slug ) {
    //define ( ‘BP_XPROFILE_SLUG’, ‘settings’ );//didnt have desirable effects. left her for documentation

    //this is essentially a clone of xprofile-settings.php, but with tweaks to change BP_XPROFILE_SLUG references tp BP_SETTINGS_SLUG
    //that way didnt change any core files, and moved it out of the upgrade stream
    require_once( WP_PLUGIN_DIR.’/mmc_misc/functions_xprof_settings_mmc.php’);

    $profile_link = $bp->loggedin_user->domain . $bp->profile->slug . ‘/’;
    $settings_link = $bp->loggedin_user->domain . $bp->settings->slug . ‘/’;

    //EDIT PROFILE
    bp_core_new_subnav_item( array(
    ‘name’ => __( ‘Edit Profile’, ‘buddypress’ ),
    ‘slug’ => ‘edit’,
    ‘parent_url’ => $settings_link,
    //’parent_slug’ => $bp->profile->slug, //left for documentation
    ‘parent_slug’ => $bp->settings->slug,
    ‘screen_function’ => ‘xprofile_screen_edit_profile_mmc’,
    ‘position’ => 50, //magic number based on current items already there in SETTINGS tab
    ‘user_has_access’ => bp_is_my_profile() //ADDED, NOT IN ORIGINAL WHEN IN BP-XPROFILE.PHP
    ) );

    //CHANGE AVATAR
    bp_core_new_subnav_item( array(
    ‘name’ => __( ‘Change Avatar’, ‘buddypress’ ),
    ‘slug’ => ‘change-avatar’,
    ‘parent_url’ => $settings_link,
    //’parent_slug’ => $bp->profile->slug, //left for documentation
    ‘parent_slug’ => $bp->settings->slug,
    ‘screen_function’ => ‘xprofile_screen_change_avatar_mmc’,
    ‘position’ => 60, //magic number based on current items already there in SETTINGS tab
    ‘user_has_access’ => bp_is_my_profile() //ADDED, NOT IN ORIGINAL WHEN IN BP-XPROFILE.PHP
    ) );

    }//end if

    }//end function
    add_action( ‘wp’, ‘mmc_bpsetupnav_forsettings’, 2 );
    add_action( ‘admin_menu’, ‘mmc_bpsetupnav_forsettings’, 2 );
    `

    note the TWO add-actions at the end. also taken from example at bp-xprofile.php. why this and not bp_setup_nav.. i dont know!

    ggod luck
    mario

    #91556
    modemlooper
    Moderator
    #89810
    Hugo Ashmore
    Participant

    @helverk

    You wrote: But what I am ever going to do with it? in reference to your .htaccess file

    You don’t do anything with the file the server does. The server must be able to write to the file to make any changes required automatically.

    Have you tried going to the permalinks menu in the dashboard and set it to anything other than default, just change to day/month and save and tell us what the screen says , if there are any messages about not being able to write to the file or whether it simply kicks things into life.

    I also note that your base is not ‘/’ root but ‘/wordpress/’ which may not help matters I presume you simply installed into the MAMP? web sites directory, it would be worth reading up on how to configure vhost containers and simple host file dev domains so you can run a site as a make believe top level domain.

    #89426
    rayd8
    Member

    I found this fix and it appears to be working for me:

    1. Open the index.php, save it to your theme as posts-page.php (or whatever template name you like).
    2. Edit the newly created posts-page.php file and place the following at the top to create a page template:

    `<?php
    /*
    Template Name: Posts Page
    */
    ?> `

    3. Now scroll down in the posts-page.php to the beginning of the WordPress loop and just before the line “ add this one line of code “ Note: (5 == the number of post to show you can change this to whatever you want.)
    4. Save the posts-page.php file.
    5. In your WordPress/BuddyPress admin panel create a new page called “Blog” (or something similar) and select “Posts Page” under Template.
    6. Publish page.

    You should now be able to go to your Settings -> Reading menu and set a static page and select your Posts Page to show your blog posts.

Viewing 25 results - 376 through 400 (of 515 total)
Skip to toolbar