1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.2 Inserting User Avatar in the Header does not work

Discussion in 'Styling and Customization Questions' started by maman, Jan 21, 2014.

  1. maman

    maman Member

    What I need to achieve:
    When the user is logged in, I want his/her avatar + summary info shown in the side bar to appear in the top right corner of the header.

    What I did:
    I pasted this in the header template:
    What I got:
    Nothing. There was no change to the header. However, I tried adding the same couple of lines to other templates and it worked as expected, i.e. the user avatar+summary appear wherever the code is pasted.

    I would appreciate it if someone can help me understand why is that, and if there is a better way to do what I am trying to do.

    Thank you in advance

    P.S. I am new to this thing. Please feel free to state the obvious!
  2. Brogan

    Brogan XenForo Moderator Staff Member

    The data probably isn't exposed for that template.

    Which code are you adding to which template?
  3. maman

    maman Member

    Added only the code above to the "header" template, as shown in the snapshot:

    Please tell me I did something silly and it is easy to fix :)

    Many thanks for your response!
  4. Brogan

    Brogan XenForo Moderator Staff Member

    Perhaps it might be easier if you explain what it is you are trying to do.

    Why are you trying to add a sidebar to the header?
  5. katsulynx

    katsulynx Well-Known Member

    He wants to move or copy the first block of the sidebar, containing avatar, post count, likes and tropy points to the header.
  6. maman

    maman Member

    Why do you think it is not working?
  7. Brogan

    Brogan XenForo Moderator Staff Member

  8. maman

    maman Member

    Thanks for the support!

Share This Page