Skip to:
Content
Pages
Categories
Search
Top
Bottom

Change Width of Buddypress and menus

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

  • RobFenech
    Participant

    @terydinho

    1) all in the css. the default theme is all based on percentages with some max-width’s in place. If you want to change that to a fixed width, run through the code via firebug and check out where the widths are coming from and simply change them in your css.

    2) yes, this is your friend here:

    `
    <?php
    global $current_user; // Get user’s information

    get_currentuserinfo();

    $user_level=$current_user->user_level;

    $user_id=$current_user->ID;

    $user_login=$current_user->user_login;

    $user_email =$current_user->user_email;

    $user_firstname=$current_user->user_firstname;

    $user_lastname=$current_user->user_lastname;

    $home_link = get_option(‘home’);
    ?>`

    then

    `<a href="” class=”profile”>View My Profile `

    and

    `<a href="” class=”messages” title=”Messages”>Messages (10)`

    and so on…


    jamesmcbennett
    Member

    @jamesmcbennett

    What pages are both of these on…

    (new to code)


    @mercime
    Keymaster

    @mercime

    @jamesmcbennett I looked at your members and forums directory and looks like something went awry with your HTML structure since last time you posted at the forums.

    With regards to your question, add the following to your theme’s stylesheet:
    `div#subnav.item-list-tabs {
    margin: -15px 0 15px !important;
    }`


    jamesmcbennett
    Member

    @jamesmcbennett

    On issue 1 @terydinho
    what page do I put the code

    On issue 2 @mercime
    It was like this from beginning, I tried to figure it out, but can’t
    the above change doesn’t work and gives very slight change of moving things right. If I change both 15’s to 115’s, it brings the edge of buddypress right allowing more room for sidebar, but doesn’t show anymore of the buddypress with ‘last active’ still chopped off to side by exact same amount.


    RobFenech
    Participant

    @terydinho

    Hi James, it depends on where you want this to show as to where you put it. I have mine in a footer file, because my client wanted a footer menu, but if you want this in your navigation, you’d have to either hard-code your nav or hook it into the end of your nav somehow.

    How are you generating your top level navigation at the moment?


    jamesmcbennett
    Member

    @jamesmcbennett

    It’s in the header (by theme)
    I just used the wp-admin page to create a menu and set it as primary navigation menu.


    @mercime
    Keymaster

    @mercime

    On issue#1 – need to clear cache. Better yet, open site with another browser. Added style works.

    On issue #2, you might also want to try this plugin https://wordpress.org/extend/plugins/buddypress-profile-menu/installation/ where you’d have to add
    `

    `
    just below your wp_nav_menu in your theme’s header.php

    Caveat: you would need to manually change the div classes/ID of the menu UL/LI in the plugin’s bp-profile-menu.php file


    RobFenech
    Participant

    @terydinho

    Save yourself the hassle if you aren’t a proficient coder and go with @mercime ‘s method of the plugin – that is quite a sweet little bit of kit :)

    Nice find @mercime :)


    jamesmcbennett
    Member

    @jamesmcbennett

    I think I messed it up, not sure what’s wrong…

    http://www.fabsie.com/forums

    I copied and pasted stylesheet
    http://pastebin.com/8JTfZ9P3


    @mercime
    Keymaster

    @mercime

    Thank you @terydinho

    @jamesmcbennett
    Delete
    `
    <?php
    global $current_user; // Get user’s information

    get_currentuserinfo();

    $user_level=$current_user->user_level;

    $user_id=$current_user->ID;

    $user_login=$current_user->user_login;

    $user_email =$current_user->user_email;

    $user_firstname=$current_user->user_firstname;

    $user_lastname=$current_user->user_lastname;

    $home_link = get_option(‘home’);
    ?>`
    from your stylesheet. You’ll then find that the style you pasted below that will work then.


    jamesmcbennett
    Member

    @jamesmcbennett

    Deleted above code from stylesheet.
    http://www.fabsie.com/forums still doesn’t work.

    Any other tips.


    jamesmcbennett
    Member

    @jamesmcbennett

    Also not sure how to get part II working.

    Plugin Installed

    header .php now reads

    `
    <html >

    <meta charset="” />

    <body id="” >

    `

    Not sure what you mean by
    “Caveat: you would need to manually change the div classes/ID of the menu UL/LI in the plugin’s bp-profile-menu.php file”


    @mercime
    Keymaster

    @mercime

    Remove code afer `

    ` in your header.php, It’s going to wreck the layout. You’ve got to ask theme developer where you can add that code in the custom navigation menu of the premium theme.

    More importantly, your layout is wrecked in the content area. Some styles added to your stylesheet like:
    `body.directory #content {
    margin: 0 34% 0 7.6%;
    width: 58.4% !important;
    }
    div#content .padder {
    margin-right: 351px;
    }
    etc.`
    have compounded the problem. Those styles were not there before nor is that one of the recommended additions at all.


    jamesmcbennett
    Member

    @jamesmcbennett

    @mercine
    Great, got it a little bigger, now back to this….
    http://www.fabsie.com/wp-content/uploads/2012/03/buddypressproblem.png

    any idea how to move the “last active” to left.


    jamesmcbennett
    Member

    @jamesmcbennett

    Flexi-header.php

    What should I modify and how do I get the profile/mesages links into the nav links?

    http://pastebin.com/ZwCEHiZy


    jamesmcbennett
    Member

    @jamesmcbennett

    Possibly this might help
    http://www.fabsie.com/wp-content/uploads/2012/03/corrections-fabsie.png

    The
    div#subnav.item-list-tabs {
    margin: 0px 0px 20px 0px !important;
    }
    moves the GREEN LINE

    I want to move the dropdown menu saying “last active” towards left so that it fits within the white rectangle (green dashed line) without being cropped.

    @mercine The above code is controlling the wrong part…..


    jamesmcbennett
    Member

    @jamesmcbennett

    So on my header page I have placed the code you provided and activated plugin to get profile link in main nav meny.

    I can either get it one line below (current http://pastebin.com/xJ5Y02nA) or by moving the new code up one or two lines, the “Profile menu” appears above the line above main nav menu. Is there a way to get it on the same line.
    http://www.fabsie.com/wp-content/uploads/2012/03/corrections-fabsie2.png


    @mercime
    Keymaster

    @mercime

    == Is there a way to get it on the same line. ==

    Adjust style of the navigation menu to add space for the new profile link on the right of the default navigation UL. Use Firebug, a Firefox add-on, to identify the styles that affect the positioning of the custom navigation and move it to the left


    jamesmcbennett
    Member

    @jamesmcbennett

    @mercime I still can’t figure out how to get it on one line……

    Here is header…
    http://pastebin.com/r1Pwi5hR

Viewing 19 replies - 1 through 19 (of 19 total)
  • The topic ‘Change Width of Buddypress and menus’ is closed to new replies.
Skip to toolbar