Forum Replies Created
-
In reply to: How to edit the Buddypress default theme navigation?
yes… unless you have a good reason….
In reply to: Pages not workingBecause it was working before doesn’t mean that it isn’t a memory issue!
To check for that I would use https://wordpress.org/extend/plugins/wp-system-health/ and run the check memory allocation limit test.
By the looks of some of those errors the problem may be the zingiri forum wordpress plugin.
Are you sure it’s compatible with buddypress? Googling parts of the error messages show other’s are having problems with it. ( Including https://wordpress.org/support/topic/error-22-and-503-on-new-installation – also see: Paul Gibbs’ post here )
If you need to keep it then I suggest you ask on http://forums.zingiri.com/
In reply to: How to edit the Buddypress default theme navigation?If your child theme hasn’t got a functions.php file then create your own in a simple text editor such as notepad++.
The first line should be just “ with nothing after it. ( The same php tags as the bp-custom.php file )
Then place something like the above nav menu function and action in between the tags….
For more info check the codex link above or http://justintadlock.com/archives/2010/06/01/goodbye-headaches-hello-menus
In reply to: Remove the “DashBoard” from the adminbarbp-custom.php goes into the plugins folder immediately under /wp-content/plugins/ not in a theme folder/directory….
In reply to: How to edit the Buddypress default theme navigation?( https://codex.wordpress.org/Navigation_Menus )
In your child theme’s functions.php file:
`function register_my_menus() {
register_nav_menus( array(
‘primary’ => __( ‘Header Navigation’ ),
‘secondary-menu’ => __( ‘Alternative Menu’ ),
‘another-menu’ => __( ‘Another Menu’ )
) );
}
add_action( ‘init’, ‘register_my_menus’ );
`In reply to: How to edit the Buddypress default theme navigation?something like filezilla ?
I just downloaded a copy of buddypress from the ‘Manual Download’ button on https://buddypress.org/download/ and it was the same as my svn link above.
If your file is different, then there may be other files that are also different!
In reply to: How to edit the Buddypress default theme navigation?in the bp-default header ( should be line 46 – 48 )
`false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘primary’, ‘fallback_cb’ => ‘bp_dtheme_main_nav’ ) ); ?>`
replace it in your child theme with something like
`<?php
if ( is_user_logged_in() ) {
wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘primary’, ‘fallback_cb’ => ‘bp_dtheme_main_nav’ ) );
} else {
wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘secondary-menu’, ‘fallback_cb’ => false ) );
}
?>`
as it is the last parameter, I don’t think false has a comma after it in this context….Make sure you back up before any edits in case something goes wrong!
nb: to use code on buddypress.org put backticks ` (normally above tab key) before and after…
Can you check your server log for php or other errors?
ie9 developer tools ‘console’ also shows a lot of errors on that particular page…..
In reply to: Creating a Group – getting a blank pageIn reply to: How to edit the Buddypress default theme navigation?I’m not sure what you mean – but according to https://codex.wordpress.org/Function_Reference/wp_nav_menu you could have ` ‘fallback_cb’ => false,`
I don’t know how you are doing the mobile menu, but couldn’t you just have $current_user logged in and out mobile menus?
If someone can guess the page such as activity, then just hiding the menu won’t stop them getting in anyway.
You wrote: some times it ends up showing a blank page
In reply to: How to edit the Buddypress default theme navigation?I’ve just tried the following on a bp test site instead of the single menu and it worked
`
<?php
if ( is_user_logged_in() ) {
wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘primary’, ‘fallback_cb’ => ” ) );
} else {
wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘secondary-menu’, ‘fallback_cb’ => ” ) );
}
?>
`nb: The test site is also using the walled garden technique…
In reply to: How to edit the Buddypress default theme navigation?It would help if you had a test site to try it out on, ie: localhost or a subdomain…
In reply to: How to edit the Buddypress default theme navigation?I’m using a customised bp-columns, which is mostly the same as bp-default.
I would just replace
`wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘primary’, ‘fallback_cb’ => ‘bp_dtheme_main_nav’ ) );`
which begins and ends with php tags with the above also wrapped in php tags….the mobile angle is something else…
In reply to: How to edit the Buddypress default theme navigation?Actually I think it should, but I didn’t try it as I was already experimenting with the above for a non bp site and tried it out on a bp test site and it worked.
I quite like this approach because you could also use the data (see link) to do other things as well…..
In reply to: How to edit the Buddypress default theme navigation?How about the following (in the header?) instead of what’s there (bp 1.5.1)
`// https://codex.wordpress.org/Function_Reference/wp_get_current_user
$current_user = wp_get_current_user();
if ( 0 == $current_user->ID ) {
wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘secondary-menu’, ‘fallback_cb’ => ” ) );
// Not logged in.
} else {
wp_nav_menu( array( ‘container’ => false, ‘menu_id’ => ‘nav’, ‘theme_location’ => ‘primary’, ‘fallback_cb’ => ” ) );
// Logged in.
}
`
? (wrapped in “ tags)In reply to: Really need help on privacy. Complete noob hereCouldn’t you do something along the lines of the walled garden technique: https://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/privacy-3/#post-113808
In reply to: Pages not workingHave you tried the suggestions on https://codex.buddypress.org/troubleshooting/blank-pages/ ?
Couldn’t you do something along the lines of the walled garden technique: https://buddypress.org/community/groups/how-to-and-troubleshooting/forum/topic/privacy-3/#post-113808
In reply to: How to make WP themes compatible with BP?In reply to: Using this website aargh!Try putting an @ sign in front of their user name ie @junglejinge
In reply to: Where are my sub-menus? – Graphene Themetry using http://pastebin.com/ and link to it….