is there any way to center the avatar in the user info block/avatar holder?

anotheralias

Well-known member
Say you want to make the user info block/avatar 140px wide - the avatar will still align left, leaving a gap of empty space to the right. Is there any way to center it? Thanks!
 
Admin CP -> Appearance -> Templates -> xenforo.css

Code:
    .avatar .img
    {
        display: block;
        background-repeat: no-repeat;
        background-position: 2px 2px;
        text-indent: 1000px;
        overflow: hidden;
        white-space: nowrap;
        word-wrap: normal;
    }

Change to:

Code:
    .avatar .img
    {
        display: block;
        background-repeat: no-repeat;
        background-position: center center;
        text-indent: 1000px;
        overflow: hidden;
        white-space: nowrap;
        word-wrap: normal;
    }

I tested this and it works.
 
Just an observation but if you increase the message template from 124px to 140px, wouldn't you also want to increase the avatar size from 96px to 112px?
 
Thanks so much Jake!

Brogan, if you mean does it -- no. If you mean, I should increase the avatar size - well, I'm still working on the CSS, I'll tackle avatar size another day. (Or more likely, after a few days of getting nowhere I'll beg someone else to tackle it for me.) :D
 
Top Bottom