*

Recent

Author Topic: Don't resize avatars...  (Read 3117 times)

Trasion

  • Guest
Don't resize avatars...
« on: July 20, 2009, 05:41:37 PM »
Right now, I uploaded a 50 by 50px avatar, and it got resized to 100 by 100px.

I wanted it to remain the normal size.

Any way to remove this? Just make the max size 150 by 150, and don't resize them... Very frustrating that it has to be 100 by 100 :(

Trasion

  • Guest
Re: Don't resize avatars...
« Reply #1 on: July 20, 2009, 05:56:31 PM »
Could someone tell me how to max the max avatar size 150 by 150 pixels, and if it's larger, THEN resize it to 150 by 150, or just deny it. If it's smaller, let it stay that size.

kurt

  • Developer
  • Hero Member
  • ******
  • Posts: 634
  • Force: +16/-1
Re: Don't resize avatars...
« Reply #2 on: July 20, 2009, 06:10:03 PM »
The file that controls the size of the avatar as it is being displayed is /pages/showprofile.php

Open it up and look for

Code: [Select]

if ($avatar == "1" ) { $avatarfileurl = '<img src=\''.$domain.'/avatars/'.$avatarfile.'\' height=\'100\' width=\'100\'>'; } else { $avatarfileurl = ''; };




and change/remove the width and height properties as you wish.

It might look a bit weird if somebody uploads a 700 by 25 pixel avatar though.

There are no controls as to the max size in pixels a person can upload, only the file size in bytes. That was left for another version.

Hope that helps.