View Full Version : first post avatar fullsize and the rest scaled down.
wilford brimley
08-26-2012, 05:05 AM
anyway to do this? either by making the first post avatar larger (150%) and then setting a restriction on avatar size OR prefered to leave first avatar the full size and then scale rest of thread avatars to 50%
Scanu
08-26-2012, 10:59 AM
anyway to do this? either by making the first post avatar larger (150%) and then setting a restriction on avatar size OR prefered to leave first avatar the full size and then scale rest of thread avatars to 50%
Just put this code on postbit or postbit_legacy template
<style>
.postbitlegacy .userinfo .postuseravatar {
<vb:if condition="$post['isfirstshown']">
height:150%;
width:150%;
<vb:else />
height:50%;
width:50%;
</vb:if>
}
<style>
I didn't test it but it should works
Lynne
08-26-2012, 03:24 PM
In the postbit_legacy, try adding this code here:
<vb:if condition="$show['avatar']">
<a class="postuseravatar" href="{vb:link member, {vb:raw post}}" title="{vb:rawphrase {vb:raw post['onlinestatusphrase']}, {vb:raw post.username}}">
<img <vb:if condition="$post[postcount] == 1">style="width:150%"</vb:if> src="{vb:raw post.avatarurl}" alt="{vb:rawphrase xs_avatar, {vb:raw post.username}}" title="{vb:rawphrase xs_avatar, {vb:raw post.username}}" />
wilford brimley
08-27-2012, 02:28 AM
scanu, that makes it so only the first post is shown.
ill try that one lynn. it works.
can you add a code to make everyone else 50%? either that or im going to just resize everyone avatars
Scanu
08-27-2012, 08:26 AM
To make everyone else's 50% try this one
<vb:if condition="$show['avatar']">
<a class="postuseravatar" href="{vb:link member, {vb:raw post}}" title="{vb:rawphrase {vb:raw post['onlinestatusphrase']}, {vb:raw post.username}}">
<img style="width:<vb:if condition="$post[postcount] == 1">1</vb:if>50%" src="{vb:raw post.avatarurl}" alt="{vb:rawphrase xs_avatar, {vb:raw post.username}}" title="{vb:rawphrase xs_avatar, {vb:raw post.username}}" />
wilford brimley
08-28-2012, 05:59 AM
how can i make it do both, 150% first and 50% the rest. i tired combining the code and got double avatars.
Scanu
08-28-2012, 06:56 AM
To make everyone else's 50% try this one
<vb:if condition="$show['avatar']">
<a class="postuseravatar" href="{vb:link member, {vb:raw post}}" title="{vb:rawphrase {vb:raw post['onlinestatusphrase']}, {vb:raw post.username}}">
<img style="width:<vb:if condition="$post[postcount] == 1">1</vb:if>50%" src="{vb:raw post.avatarurl}" alt="{vb:rawphrase xs_avatar, {vb:raw post.username}}" title="{vb:rawphrase xs_avatar, {vb:raw post.username}}" />
Before using this you must delete the old code of Lynne
wilford brimley
08-31-2012, 03:23 AM
works great. i set it to 75% and it looks perfect. thanks alot.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.