How to use navigation bar at BP Daily

Hiy,

here I'm again. Not sure with this question, but I already saw your video, still did not get how to manage the navigation bar.

I got three navigation bar:

1. At the very top are the categories
2. In the middle seems to be the new Menu from WP 3.0
3. Than the last one is the navigation from the Buddypress

My website is: http://www.sinau.me

My questions are:

1. how can I put page into the navigation bar? I want to put it in the third one, after the whole buddypress button.
2. In the middle navigation, how can I have sub-page? It seems it can not show it

Thanks a lot for the help,

ht

  • Tammie
    • WordPress Wizard

    @htjitra: The video was done before WordPress 3.0 so hasn't got the new menus in. You just use the menu function in WordPress 3.0 under appearance > menus. Create a new menu and then link it up. You can add pages and sub pages there and it will pick it all up. Pages unless you add code can only go in the wordpress menu. This is done so you can choose what you show in that menu. However under library/components/buddypress/buddypress-navigation.php (if you have buddypress) or library/components/navigation.php you can edit those files to include your own navigation if you wish.

  • htjitra
    • Design Lord, Child of Thor

    Thanks Tammy for your prompt explanation.

    I have tried with the WP Menu, yes, it works with the sub-page.

    However I still have two question:

    1) I create another (new) menu - but than I could not see it on the navigation, where is it?
    - also if I add new page, than I can not see this new page (except if I would add it in the first menu I created) => where is than the new page I created.

    2) If I understand you correct, than if I want to add something in the buddypress navigation bar (e.g. after blogs) than I need to modify the buddypress-navigation.php, correct? If it is the case, can you tell me how can I add page there? and where can I find this php file?

    thank,

    ht

  • htjitra
    • Design Lord, Child of Thor

    I found the buddypress-navigation.php but I dont know how to change it so that I can put my page "about" directly behind the "blogs" in the buddypress navigation bar. Would u mind to show me?

    also the first question is still unanswered for me.

    thx,

    ht

  • Tammie
    • WordPress Wizard

    @htjitra: Ok let me answer each of your questions.

    1. I don't know what you mean... the navigation if you are adding it you link up the menu in the wordpress section menus. Are you doing this? Please provide the steps you are using. You have to add pages to it they do not just turn up in the menu maybe this is the issue?

    2. Yes you would have to add that page. You just add the following:

    <?php wp_list_pages( 'title_li=&'); ?>

    where you want it - my suggestion would be line 50 before the closing ul:

    You can also remove the following to get rid of the custom menu:

    <div class="page-navigation"><br />
    					<?php wp_nav_menu( array('theme_location' => 'primary', 'menu_class' => 'sf-menu', 'container' => '', )); ?></p>
    <p>			<?php do_action( 'bp_nav_items' ); ?><br />
    	<div class="clear"></div><br />
    </div>

    Also please consider it is the weekend so that was why your question wasn't answered right away we do our best to respond fast but can't be instantly at all times.

  • htjitra
    • Design Lord, Child of Thor

    Dear Tammy,

    thanks a lot, I got it.

    BTW I didn't meant at all the response was slow, I just said that because I have solved my second questions, it does not mean I solved also the first one :wink:

    OK now I got how to do it, will try it soon.

    best,

    ht

  • htjitra
    • Design Lord, Child of Thor

    @Tammy,

    here I'm again, andtrying now to fix the navigation bar as you suggested above. I manged to remove the middle navigation bar (with the custom menu).

    But I could not add a new page in the last navigation bar (BP Navigation bar, after blog). I want to add page called "About". I did your suggestion:

    <?php wp_list_pages( 'title_li=&:wink:; ?>

    but there was error message. The file I'm talking about the the buddypress-navigation.php, correct?

    thx

  • htjitra
    • Design Lord, Child of Thor

    @Tammy,

    I have done what you said, add the code above in buddypress-navigation.php (in the last line). But the page doesnt appear corrently. It appear not in the navigation bar but add a new line.

    What did I do wrong?

    Also if I do the code as you said, than all pages will appear after the buddy press or ...? How could I select which pages appear in the navigation bar, which pages should not appear? Also can I use the new WP 3.0 menu function?

    thx

  • Tammie
    • WordPress Wizard

    @htjitra: First up you've got to add before the closing ul as I said it will produce a list. Next up you need to look at the function to see about excluding pages:

    http://codex.wordpress.org/Function_Reference/wp_list_pages

    If you add it after this:

    <?php if ( bp_is_active( 'blogs' ) && bp_core_is_multisite() ) : ?>
    							<li<?php if ( bp_is_page( BP_BLOGS_SLUG ) ) : ?> class="selected"<?php endif; ?>
    								<a>/<?php echo BP_BLOGS_SLUG ?>/" title="<?php _e( 'Blogs', TEMPLATE_DOMAIN ) ?>"><?php _e( 'Blogs', TEMPLATE_DOMAIN ) ?></a>
    				<?php endif; ?>

    It will work I've tested it there is something wrong in your code and I can't see that unless you paste it.

    You've already got a new wordpress navigation bit you've just removed - up to you if you want to put it back.

  • htjitra
    • Design Lord, Child of Thor

    @Tammy,

    now I managed w BP it works under the BuddyPress, but in the front page it doesn't work.

    Should I add also the code into the navigation.php? or in the index.php?

    BTW for the frontpage I'm not using the standard BP-Daily frontpage, but just use the simple blog function. Last time you told me to remove the home.php, and add an index.php.

    How to make it work in the frontpage?

  • Tammie
    • WordPress Wizard

    @htjitra: I am sorry I really don't know what you mean I've given you the code to get it to work and told you where to add :slight_frown:

    Can you link in what you have so I can see please. You are meant to be adding this as already stated in buddypress-navigation.php under library/components/buddypress so haven't a clue why you are saying about navigation.php and index.php.

    As stated right at the start of this thread:

    However under library/components/buddypress/buddypress-navigation.php (if you have buddypress) or library/components/navigation.php you can edit those files to include your own navigation if you wish.

    I told you to remove / adjust those pages for a completely different issue nothing to do with navigation menus - I think you are getting confused as to what you are doing. Just use the code I've given in the file I said and everything will work.

  • htjitra
    • Design Lord, Child of Thor

    I meant I have done as you said and tried to put it in several positions too, but it seems it doesnt work. Below is the code, where should I put it?

    Attached is the screenshot of the code in buddypress-navigation.php

  • htjitra
    • Design Lord, Child of Thor

    @Tammy

    sorry it seems that all is OK now. Maybe because WP-Cache that I can not see the change immediately, and have to check with other browser.

    Thx a lot for your excellent support, and sorry for the trouble.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.