Edit Main Header

This topic is: Resolved

This is a PRIVATE forum for verified users only, to view the replies/answers, you must be logged in!

This topic contains 9 replies, has 3 voices, and was last updated by  Thakksy 1 year, 11 months ago.

  • Author
    Posts
  • #6000

    Thakksy
    Member
    Post count: 321

    Hey, do you guys know which file i must open if i want to add some code to the main header.

    To be more specific i want to add some code that will show the current logged in users avtar after the last main menu link next to login/log out. Cheers

    site is at http://www.cruisehive.com

  • #6017

    Jacob
    Staff
    Post count: 2323

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #6037

    Thakksy
    Member
    Post count: 321

    Thanks for providing that link but it’s for login/out. I have Buddypress which already offers these features for menu. All i want to do is add the following code after the last menu link in main menu.

    $myvalue = $_GET('<?php global $userdata; get_currentuserinfo(); echo get_avatar( $userdata->ID, 46 ); ?>');

    This will add the current logged in users avatar in the main menu bar. And will show a generic avatar for logged out members.

    just dont know how or where to add this code! I already have custom-functions and childtheme all set up

  • #6047

    Max
    Staff
    Post count: 3150

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #6061

    Thakksy
    Member
    Post count: 321

    it works but if i just put my site URL when you click on the avatar it just goes to 404 not found. Also how to move it so it is next to the last main menu item so next to the login/log out drop down link. Thanks

  • #6063

    Thakksy
    Member
    Post count: 321

    Sorry for bumping the post but managed to move it to the left, just gotta sort out the link issue 🙂

  • #6085

    Max
    Staff
    Post count: 3150

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #6090

    Thakksy
    Member
    Post count: 321

    The best is for the link to link to the currently logged in users profile then the register/login page for those currently logged out.

  • #6097

    Max
    Staff
    Post count: 3150

    Hey there, You must be logged in to view this reply!

    Login | Register | Forgot Password?

  • #6113

    Thakksy
    Member
    Post count: 321

    It’s all done :). Without you doing the code i wouldn’t have been able to do it so thanks so much for doing that.

You must be logged in to reply to this topic.

This is a PRIVATE forum for verified users only, to view the replies/answers, you must be logged in!