Skip to:
Content
Pages
Categories
Search
Top
Bottom

[Resolved] BP-columns: cant get pages to display in footer Unless logged in as admin.

  • Avatar of jamieh05gmailcom
    jamieh05@gmail.com
    Member

    @jamieh05gmailcom

    Hi Hope someone can help i am a little stumped here, i have buddypress installed and can only view my footer pages when logged in as admin.

    If i log out they disappear from view, even if i type in the url i get a 404 error. If i then log in as admin they show up and the text is displayed.

    I have a custom menu set up in wordpress, Appearance – menus, labelled as footer.

    I am running a custom theme with bp-columns.

    I was wondering if anyone could point me in the direction of how to get them to show up all the time as the pages are for terms, privacy, blog, about us etc. I am not a programmer so please be patient. Any help much appreciated.

    Thanks

Viewing 25 replies - 1 through 25 (of 39 total)
  • Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    @goldbrick said in my profile update

    Hi Mercime

    Thanks for the reply, i did post over at buddypress but did not get a response so i thought i would try here.

    By Footer pages i mean i have created pages in wordpress called terms, privacy, about us, blog etc. and they oonly show up in the footer area of the site when i am logged in as admin, if you where to view the site now in the footer there is just a copywrite text in the footer.

    Even if i type the URL of the page into the browser the page does not display it comes up with a 404 error. If i then log in as admin and do the same the page will display?

    I hope i have explained it ok.

    Thanks
    Jay

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    Continued from http://wordpress.org/support/topic/pages-not-showing-on-buddypress-system?replies=4

    @jamieh05atgmail.com and @goldbrick

    == show up in the footer area of the site when i am logged in as admin, ==

    Still not clear. If you’ve added template codes to “call” Pages in specific areas of the site, then you should see the Pages whether you’re admin or not, unless you’ve added a conditional statement `if (is_super_admin)` in front of the code … did you?

    It would help if you posted a link to a screenshot of what you see as Super Admin or Site Admin along with site URL or another screenshot of what’s happened next. What theme are you using?

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    yes thats right,

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    ok site url is http://www.sportzmonkey.com i will take a screen shot of the site when logged in

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    i am using bp-columns theme

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    Will be checking it out.

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    here the php code from the footer.php it is using the custom menu from wordpress to display the pages in the footer.

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    EDIT – “Unable to connect. Firefox can’t establish a connection to the server at http://www.sportzmonkey.com
    Tried opening the site in Chrome and Safari, the site just doesn’t open.

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    sorry may have been me try this http://www.sportzmonkey.com/

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    @goldbrick put a backtick before and after your code because it’s not rendering well in this forum – aside from wrecking the layout :-(

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    `

    `

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    heres a link to a screen shot of me logged in you will see the pages now showing the the footer.

    http://wallowit.com/images/screenshot.jpg

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    @goldbrick that screenshot link goes to “Unable to connect. Firefox can’t establish a connection to the server at wallowit.com.”

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    sorry about this Mercime i think my server is playing up i will look in to it now

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    it shold be working now sorry

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    @goldbrick screenshot link not working, same error message.

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    Hi Mercime

    Dont why that is but here i have put it up on a page of a site i dont use.

    http://www.allinonemedia.co.uk/
    See is this helps.

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    Ok, I see the screenshot now. And yes, you have links to the Pages (text so small I can’t read them all) at the footer of your theme.

    In actual site (home page) looking at page source, I see the empty div
    `

    `
    wp_nav_menu is being called but not rendered. This is because the function is not supported in your theme.

    Open up functions.php file of your theme http://themes.svn.wordpress.org/bp-columns/1.2/functions.php
    and add the following line just above closing `?>`

    `add_action( ‘init’, ‘register_goldbrick_menus’ );

    function register_goldbrick_menus() {
    register_nav_menus(
    array(
    ‘footer-menu’ => __( ‘Footer Menu’ )
    )
    );
    }`
    Then save and upload.

    Open up your footer.php and replace:

    `<?php wp_nav_menu(
    array(
    ‘theme_location’ => ”,
    ‘menu’ => ”,
    ‘container’ => ”,
    ‘container_class’ => ”,
    ‘container_id’ => ”,
    ‘menu_class’ => ”,
    ‘menu_id’ => ”
    )
    ); ?>`

    with

    ` ‘footer-menu’ ) ); ?>`

    Then save and upload.

    In dashboard Appearance > Menus. Choose Footer Menu and add the links.

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    Thanks Mercime

    But they still dont show on the home page, my functions file had a bit more code in it then what was shown above here it is just incase this makes a difference
    `<?php

    register_sidebars(1,
    array(
    ‘name’ => ‘left sidebar’,
    ‘before_widget’ => ‘

    ‘,
    ‘after_widget’ => ‘

    ‘,
    ‘before_title’ => ‘

    ‘,
    ‘after_title’ => ‘


    )
    );

    //function myavatar_add_default_avatar($url){
    //return get_stylesheet_directory_uri().’/_inc/images/default-avatar.png’;
    //}
    //add_filter(‘bp_core_mysteryman_src’, ‘myavatar_add_default_avatar’);

    function my_default_get_group_avatar($avatar){
    global $bp, $groups_template;
    if(strpos($avatar,’group-avatars’)){
    return $avatar;
    }else{
    $custom_avatar = get_stylesheet_directory_uri().’/_inc/images/default-avatar.png’;
    if($bp->current_action == “”)
    return ‘group->name).’” />’;
    else
    return ‘group->name).’” />’;
    }
    }
    add_filter(‘bp_get_group_avatar’, ‘my_default_get_group_avatar’);

    add_action( ‘init’, ‘register_goldbrick_menu’ );

    function register_goldbrick_menu() {
    register_nav_menu( ‘footer-menu’, __( ‘Footer Menu’ ) );
    }
    ?>`

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    I have corrected the original code posted above to be added in the functions.php file. Forgot to add `=>`

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    Hi Mercime

    I added the extra bit still no joy, just an example of whats happening if you click on the create account button on the home page then you will see a tick box saying agree to our terms there is a link there to that page, if you click that you will get a 404 error, However when i log in as admin that same url will become visible.

    thanks for all your help so far i really appericate this.

    Avatar of @mercime
    @mercime
    Keymaster

    @mercime

    == I added the extra bit still no joy ==

    Hmm, I know the code works. I assume you revised the whole wp_nav_menu code in your functions.php with the whole code I posted above.
    - Post content of your footer.php here.
    - Did you create a new menu in Appearance > Menus – Choose Footer Menu from Theme Locations and clicked on Save after creating the links?

    == if you click that you will get a 404 error, ==

    - Deactivate all plugins except BuddyPress then re-run Settings > Permalinks – Save.

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    I did revise the code in the functions.php file with the whole code you posted above.

    Here is my footer.php code.
    `

    `

    i also created a new menu called footer menu and added the links but still not showing.

    I have also deactivated the plugins and redone the permalinks but still page showing 404 error

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    heres the complete function.php code
    `<?php

    register_sidebars(1,
    array(
    ‘name’ => ‘left sidebar’,
    ‘before_widget’ => ‘

    ‘,
    ‘after_widget’ => ‘

    ‘,
    ‘before_title’ => ‘

    ‘,
    ‘after_title’ => ‘


    )
    );

    //function myavatar_add_default_avatar($url){
    //return get_stylesheet_directory_uri().’/_inc/images/default-avatar.png’;
    //}
    //add_filter(‘bp_core_mysteryman_src’, ‘myavatar_add_default_avatar’);

    function my_default_get_group_avatar($avatar){
    global $bp, $groups_template;
    if(strpos($avatar,’group-avatars’)){
    return $avatar;
    }else{
    $custom_avatar = get_stylesheet_directory_uri().’/_inc/images/default-avatar.png’;
    if($bp->current_action == “”)
    return ‘group->name).’” />’;
    else
    return ‘group->name).’” />’;
    }
    }
    add_action( ‘init’, ‘register_goldbrick_menus’ );

    function register_goldbrick_menus() {
    register_nav_menus(
    array(
    ‘footer-menu’ => __( ‘Footer Menu’ )
    )
    );
    }
    ?>`

    Avatar of goldbrick
    goldbrick
    Member

    @goldbrick

    would there be any code somewhere to hide pages unless an admin user?

Viewing 25 replies - 1 through 25 (of 39 total)

You must be logged in to reply to this topic.