Skip to:
Content
Pages
Categories
Search
Top
Bottom

Creating NAV Bar

  • Avatar of armandmorin
    armandmorin
    Participant

    @armandmorin

    How do you insert the BuddyPress NAV bar into a theme? I’ve tried to copy header information from the BuddyPress Theme, but got a function error.

    Any thoughts?

Viewing 8 replies - 1 through 8 (of 8 total)
  • Avatar of Bowe
    Bowe
    Participant

    @bowromir

    you should copy the code directly from header.php:

    Here’s the div with the code

    [snip]

    That should work fine if you’re using it for a theme which is buddypress ready/compatbile (which I presume it is :)). If you’re copying it into a normal WP theme without BP installed you get errors :)

    Avatar of robthecomputerguy
    robthecomputerguy
    Participant

    @robthecomputerguy

    Oh I will have this question and it was very helpful for me to see it, so thank you both!! :)

    Avatar of armandmorin
    armandmorin
    Participant

    @armandmorin

    I’m using a theme modified with the BuddyPress Template Pack.

    I added the code you pasted above… thanks for that.

    I got this error message.

    Fatal error: Call to undefined function bp_dtheme_page_on_front()

    Avatar of armandmorin
    armandmorin
    Participant

    @armandmorin

    Any ideas on this error?

    Avatar of Andy Peatling
    Andy Peatling
    Keymaster

    @apeatling

    The above code is out of date, you can find the latest in /wp-content/plugins/buddypress/bp-themes/bp-default/header.php

    Avatar of armandmorin
    armandmorin
    Participant

    @armandmorin

    Andy, I still get the same error….

    Fatal error: Call to undefined function bp_dtheme_page_on_front()

    Avatar of Gold Ratio Design
    Gold Ratio Design
    Participant

    @goldratio

    @armandmorin: if you’re still having this issue, i think the problem may be in the theme heading. If you are creating a new theme from the buddypress theme pack, then adding ‘Template: bp-default’ to your theme header *should* resolve this issue. Hope this helps!

    /*
    Theme Name: Minimal-BP (BuddyPress BuddyPack)
    Theme URI: http://www.goldratio.org
    Description: A theme from Gold Ratio Designs
    Version: 1.2
    Author: J.Y.
    Author URI: http://goldratio.org
    Template: bp-default
    Tags: buddypress, ,two-columns, minimal
    */

    Avatar of bluehornetstudios
    bluehornetstudios
    Member

    @bluehornetstudios

    I don’t know if you’ve resolved this on your own, but I think the problem is that if you are using the BP template pack, Buddypress’s functions.php is not loading. I don’t know where the function is that loads it but I just added an include in bp-custom.php to load it before any of the other scripts.

    Like this:

    $bp_functions_file = ABSPATH . ‘wp-content/plugins/buddypress/bp-themes/bp-default/functions.php’;
    include $bp_functions_file;

    There’s probably a better way but that was a quick fix I used to fix that error.

    PS. adding “Template: bp-default” to my style.css didn’t work for me either.
    PPS. I am using the freshnews theme by woothemes.

Viewing 8 replies - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.