[Answered] Avatar Frames

Status
Not open for further replies.
#1
I want to add some frames for user avatar like this:
4khiaPD.png 9672hp2.png 8kBOY0i.png and some more...
In what template I can add the code of they and how I can do it?
 

Similar threads

XenForo Rocks

Team Member
Administrator
Moderator
+Lifetime VIP+
Contributor
ViP
True Member
Suppliers
Registered
#7
ok its just few simple template edits and this tut is for Audentio theme

1.Login to Admin CP and do in Appearance >> styles >> your style >> templates .
2.Search for template "message_user_info"
3.Find

Code:
<div class="avatarHolder {$avatarCollapseStateClass}">
Replace

Code:
<div class="avatarHolder {$avatarCollapseStateClass}
{xen:if '{xen:helper ismemberof, $user, 3}', 'avatarOutline_admin'}
{xen:if '{xen:helper ismemberof, $user, 4}', 'avatarOutline_moderator'}
{xen:if '{xen:helper ismemberof, $user, 11}', 'avatarOutline_contributor'}
{xen:if '{xen:helper ismemberof, $user, 6}', 'avatarOutline_vip'}
{xen:if '{xen:helper ismemberof, $user, 2}', 'avatarOutline_registered'}">
where numbers 3,4,11,6,2 are the usergroup numbers

4.Now in extra.css add

Code:
.messageUserBlock div.avatarOutline_registered
{
background: #FFFFFF url('http://i.imgur.com/kFFmXYE.png') no-repeat;
}
.messageUserBlock div.avatarOutline_vip
{
background: #FFFFFF url('http://i.imgur.com/2AYGEpN.png') no-repeat;
}
.messageUserBlock div.avatarOutline_contributor
{
background: #FFFFFF url('https://i.imgur.com/XdzmSNS.png') no-repeat;
}
.messageUserBlock div.avatarOutline_moderator
{
background: #FFFFFF url('http://i.imgur.com/w6G8G7p.png') no-repeat;
}
.messageUserBlock div.avatarOutline_admin
{
background: #FFFFFF url('https://i.imgur.com/bn96CZe.png') no-repeat;
}
5.Improve your css for better look and style yourself ,and while writing css as per your usergroups it should be in a format of lower group to higher otherwise you will have issues..

i had done this successfully on my localhost see attachment

1bt16Nh.png

PS: if anyone has free time to create frame for xenforo.rocks , then do it i will apply it here :D
 
Last edited:

willypt

Your friend
Registered
#8
Sorry entering the discussion, but i would love to have something like that too. Is it possible to user the same code work on Tactical theme...
 

XenForo Rocks

Team Member
Administrator
Moderator
+Lifetime VIP+
Contributor
ViP
True Member
Suppliers
Registered
#9
its same for all themes of xenforo and as I said I had done this on audentio themes framework so it's also possible in tactical theme .

If you got any issues don't hesitate to contact me :)
 
#10
It'
ok its just few simple template edits and this tut is for Audentio theme

1.Login to Admin CP and do in Appearance >> styles >> your style >> templates .
2.Search for template "message_user_info"
3.Find

Code:
<div class="avatarHolder {$avatarCollapseStateClass}">
Replace

Code:
<div class="avatarHolder {$avatarCollapseStateClass}
{xen:if '{xen:helper ismemberof, $user, 3}', 'avatarOutline_admin'}
{xen:if '{xen:helper ismemberof, $user, 4}', 'avatarOutline_moderator'}
{xen:if '{xen:helper ismemberof, $user, 11}', 'avatarOutline_contributor}
{xen:if '{xen:helper ismemberof, $user, 6}', 'avatarOutline_vip}
{xen:if '{xen:helper ismemberof, $user, 2}', 'avatarOutline_registered}">
where numbers 3,4,11,6,2 are the usergroup numbers

4.Now in extra.css add

Code:
.messageUserBlock div.avatarOutline_registered
{
background: #FFFFFF url('http://i.imgur.com/kFFmXYE.png') no-repeat;
}
.messageUserBlock div.avatarOutline_vip
{
background: #FFFFFF url('http://i.imgur.com/2AYGEpN.png') no-repeat;
}
.messageUserBlock div.avatarOutline_contributor
{
background: #FFFFFF url('https://i.imgur.com/XdzmSNS.png') no-repeat;
}
.messageUserBlock div.avatarOutline_moderator
{
background: #FFFFFF url('http://i.imgur.com/w6G8G7p.png') no-repeat;
}
.messageUserBlock div.avatarOutline_admin
{
background: #FFFFFF url('https://i.imgur.com/bn96CZe.png') no-repeat;
}
5.Improve your css for better look and style yourself ,and while writing css as per your usergroups it should be in a format of lower group to higher otherwise you will have issues..

i had done this successfully on my localhost see attachment

View attachment 13279

PS: if anyone has free time to create frame for xenforo.rocks , then do it i will apply it here :D
It's giving me this error:
The following error occurred:
The following templates contained errors and were not saved: message_user_info: 1) Line 72: Template syntax error.


Line 72 is:
Code:
<dd itemprop="gender"><xen:if is="{$user.gender} == 'male'">{xen:phrase male}<xen:else />{xen:phrase female}</xen:if></dd>
The error only happens when I add the code, I'm using UI.X

EDIT: other things, where I can get the usergroup number
 
Last edited:

XenForo Rocks

Team Member
Administrator
Moderator
+Lifetime VIP+
Contributor
ViP
True Member
Suppliers
Registered
#11
It'

It's giving me this error:
The following error occurred:
The following templates contained errors and were not saved: message_user_info: 1) Line 72: Template syntax error.


Line 72 is:
Code:
<dd itemprop="gender"><xen:if is="{$user.gender} == 'male'">{xen:phrase male}<xen:else />{xen:phrase female}</xen:if></dd>
The error only happens when I add the code, I'm using UI.X

EDIT: other things, where I can get the usergroup number
you are using which version of uix?
 

XenForo Rocks

Team Member
Administrator
Moderator
+Lifetime VIP+
Contributor
ViP
True Member
Suppliers
Registered
#16
It'

It's giving me this error:
The following error occurred:
The following templates contained errors and were not saved: message_user_info: 1) Line 72: Template syntax error.


Line 72 is:
Code:
<dd itemprop="gender"><xen:if is="{$user.gender} == 'male'">{xen:phrase male}<xen:else />{xen:phrase female}</xen:if></dd>
The error only happens when I add the code, I'm using UI.X

EDIT: other things, where I can get the usergroup number
Ok it's still same tut for uix 1.5.4 that I have , also if you can send me your site details with few login details in pm I can setup that for you :)
 
#17
Ok it's still same tut for uix 1.5.4 that I have , also if you can send me your site details with few login details in pm I can setup that for you :)
When I replace that code I get the error I jsut sended on the last message, my template doesn't even have the {$avatarCollapseStateClass}
 
Status
Not open for further replies.

Similar threads

Top