The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
highly needed: Profile pic creates avatar
this way, when someone uploads a profile picture, it automatically makes an avatar. i notice some users create either one or the other which is just confusing.
so, it'd be nice to be able to upload a pic, and that becomes the avatar as well as profile pic. |
#2
|
||||
|
||||
I'm just curious; why have both if you're only going to utilize one of them?
|
#3
|
|||
|
|||
I've got one big board (about 15,000 members) where everybody uses the avatar feature, but hardly anyone uses the profile picture.
I'm developing a new vB system that I hope to make into a big board that promotes more interactive profiles. So far, the beta run has a number of users uploading profile pictures, but hardly anyone using avatars. So, seeing as how both forums are complete oppisites, it'd be much nicer to see a hack that would convert a profile picture into a smaller avatar. P.S. are you asking as a possible coder, or out of curiousity? |
#4
|
||||
|
||||
I asked out of curiosity, though, I did something like this before using UBB Classic. I haven't tried it with vB.
|
#5
|
|||
|
|||
Quote:
|
#6
|
||||
|
||||
Personally, what I'd do is keep one of the fields active (let's say avatar); meaning disable the profile picture in the Usergroup permissions. Set the avatar file dimension and file size as well. Then change the phrase of avatar to "avatar/profile picture". The only template editing you'll need to do is with the postbit or postbit_legacy and memberlist templates. It is there that you will need to manually set the dimensions of the image to appear. If you don't then the image will appear to the dimension size you've specified in the Usergroup settings. In your public members profile pages the images will appear normal.
This way if you ever want to re-activate the profile picture for something else you have the option to do so. |
#7
|
|||
|
|||
Quote:
If that sounds right.. how would I set the avatar size displayed in postbit legacy? Also ould this call the full picture, or dynamically resize it? I'll try this out tonight. since a number of members have signed up with profile pics, i'm going to try and use profile pics and have the postbits dynamically resize the profile pic into avatar size. can you help with instructions that way? this might turn out to be a useful hack for others too. |
#8
|
||||
|
||||
Yup, you got it. The image won't dynamically resize the picture in the way you probably want. If anything it'll go along the dimensions of the <td> or <div> setting you lay out in the templates. In the postbit template you'll probably see this (on a default template):
Code:
<if condition="$show['avatar']"><td class="alt2"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" $post[avwidth] $post[avheight] alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a></td></if> Code:
<if condition="$show['avatar']"><td class="alt2"><a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" width="100px" height="100px" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a></td></if> I know this isn't what you wanted exactly but for me if I can avoid messing with the PHP files I'll do so. However, if this solution is not what you want then I would make a request in either the Service or Unpaid Modification forums. |
#9
|
|||
|
|||
Thanks for the code. Is there such thing as code to constrain proportions? That way not everybodies pics are the same size (ie 50x50). Also, the fact that it loads up a full size image for each page would take up alot of bandwidth especially for a big board. It looks like this isn't an easily done mod then, huh? I looked up image resize hacks on vb.org, and doesn't look like any hack is capable of this yet.
|
#10
|
||||
|
||||
Yup. The fix I'm providing is merely a temporary solution but not a definitive solution. To resize the dimensions dynamically and to proportion + rescale the file size is not an easy mod from the way I'm looking at it.
I haven't checked out the latest image resize hack (for vB 3.6) but all the others prior to it does take a toll on server load since it changes the file properties after it's loaded. I could be wrong but I think attachments and software like PhotoPost resizes and rescales the images on the upload. That would be ideal in your case. |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|