Forum Replies Created
-
@Greg thank you so much. something so simple but so useful when creating our own templates. I dont know if you still participate in these forums but thanks nonetheless.
I have to go now, but I will post later on when I get back to this. Thanks for your help so far really appreciated!
Some of code in the post got erased sorry!
Thanks for your reply i started with a new theme and was able to just comment them out. I have now coded in one of the pages where i want it (in front of members) and i have used a plugin to remove the WordPress created page (of same name). However now when i select it it does not indicate on the menu as being the currently selected page.
( bp_is_page( BP_PROJECTS_SLUG ) ) : ?> //i think this statement is wrong because —->
THIS DIDNT WORK PROPERLY I HAD TO CODE IN LINK MANUALLY
<li class=”selected”>
<a href="//” title=””>MANUALLY
<li class=”selected”>
<a href="/projects/” title=””>( bp_is_page( ‘projects’ ) ) : ?>
( bp_is_active( ‘projects’ ) ) : ?>
i tried all these conditions but it still doesnt work.
i have also used this code in my functions.php (its from another forum post, maybe i havent used it right?) —->
<?php
/*Define slugs*/
define(‘BP_PROJECTS_SLUG’, ‘projects’); /* this will show up as http://yourdomain.com/projects *//*Add slug as a root component*/
function page_setup_root_component()
{
bp_core_add_root_component( BP_PROJECTS_SLUG );
}
add_action( ‘plugins_loaded’, ‘page_setup_root_component’, 2 );/*Show defined slug*/
function bp_show_page() {
global $bp, $current_blog;if ( $bp->current_component == BP_PROJECTS_SLUG && $bp->current_action == ” ) {
bp_core_load_template( ‘projects’, true ); /*replace example with the name that of the template you upload*/
}
}
add_action( ‘wp’, ‘bp_show_page’, 2 );/*For extra functionality you can add a title for that page*/
function page_titles( $title, $b ) {
global $bp;if ( $bp->current_component == BP_PROJECTS_SLUG && $bp->current_action == ” ) {
$title = __( ‘Projects’, ‘buddypress’ ); /*change Example with what you want the title of your page to be*/
}
return $title;
}
add_filter( ‘bp_page_title’, ‘page_titles’, 10, 2 );?>
Im using one called Citizen Kane. It is easy to ass pages to the nav menu because the creator must have made it that they join on the end of the nav items (buddypress) however there is no option to delete buddypress pages etc. I have tried going into the header.php and commenting out the menu items. Im not sure. Going to have another check maybe I did not comment out the – Buddypress header.php part & – the Citizen Kane header.php. Thanks for your prompt reply btw