Is there any way to enlarge only my avatar and not have any others affected? I would like mine to be larger while keeping the size of the others intact.
Not with some coding, I believe.
Try the following instructions.
In Load.php, replace,
// If we're always html resizing, assume it's too large.
if ($modSettings['avatar_action_too_large'] == 'option_html_resize' || $modSettings['avatar_action_too_large'] == 'option_js_resize')
With,
// If we're always html resizing, assume it's too large.
if (!$user_info['is_admin'] && ($modSettings['avatar_action_too_large'] == 'option_html_resize' || $modSettings['avatar_action_too_large'] == 'option_js_resize'))
Now in Profile.php, replace,
function makeAvatarChanges($memID, &$post_errors)
{
global $modSettings, $sourcedir, $db_prefix;
with,
function makeAvatarChanges($memID, &$post_errors)
{
global $modSettings, $sourcedir, $db_prefix, $user_info;
Replace,
// Should we check dimensions?
elseif (!empty($modSettings['avatar_max_height_external']) || !empty($modSettings['avatar_max_width_external']))
With,
// Should we check dimensions?
elseif (!$user_info['is_admin'] && (!empty($modSettings['avatar_max_height_external']) || !empty($modSettings['avatar_max_width_external'])))
And finally replace,
// Check whether the image is too large.
elseif ((!empty($modSettings['avatar_max_width_upload']) && $sizes[0] > $modSettings['avatar_max_width_upload']) || (!empty($modSettings['avatar_max_height_upload']) && $sizes[1] > $modSettings['avatar_max_height_upload']))
With,
// Check whether the image is too large.
elseif (!$user_info['is_admin'] && ((!empty($modSettings['avatar_max_width_upload']) && $sizes[0] > $modSettings['avatar_max_width_upload']) || (!empty($modSettings['avatar_max_height_upload']) && $sizes[1] > $modSettings['avatar_max_height_upload'])))
Cheap hax. 8)
I will give it a shot and let you know if it works. Thanks for the reply.
.. or simple change the settings for avatar size, upload YOUR avatar and then restore the settings :)
Now, why didn't I think of that?
Thanks feline, but that doesn't do it. If I change the size of mine, everyone's get changed also. If I put it back the way it was, all including mine gets changed. I'm at a loss with this one.
Lainaus käyttäjältä: faeriedust - huhtikuu 29, 2011, 04:04:04 IP
Thanks feline, but that doesn't do it. If I change the size of mine, everyone's get changed also. If I put it back the way it was, all including mine gets changed. I'm at a loss with this one.
Have you tried my instructions?
Lainaus käyttäjältä: faeriedust - huhtikuu 29, 2011, 04:04:04 IP
Thanks feline, but that doesn't do it. If I change the size of mine, everyone's get changed also. If I put it back the way it was, all including mine gets changed. I'm at a loss with this one.
You have UPLOAD your avatar? Any other don't work.
I have this done on my server...
I've followed Project Evolutions instructions but that didn't work. Every time I try to change the size, it still does it for all avatars not just mine. I even tried some of my own tricks too. No cigar. I'm totaly at a loss now.
Lainaus käyttäjältä: faeriedust - huhtikuu 30, 2011, 02:09:20 IP
I've followed Project Evolutions instructions but that didn't work. Every time I try to change the size, it still does it for all avatars not just mine. I even tried some of my own tricks too. No cigar. I'm totaly at a loss now.
After you finished all the code changes (can you double check you made all the changes), did you upload a new avatar? I think SMF resizes the avatar you uploaded previously then stores it which is why the size wouldnt change.
I did the code changes, but since I've never done this before, I keep finding mistakes. Every time I go over it, I find another thing I goofed up on. I'm really not good at this at all. I'll keep trying but won't upload the file until I believe it's right. Don't want to ruin it for everyone.
If you attach Load.php and/or Profile.php I wont have a problem doing them for ya? ;)
These are the files you requested. I so appreciate your help with this.
Give these a shot.
I put the new php's in place and uploaded a new avatar, and you can see when it loads the avatar, it's bigger. But as soon as the topic fully loads, it goes right back to the small size. (sigh) I think this is hopeless.
Just thinking....should the sizes in the admin avatars section be changed to any other setting outside of the default? Would that make any difference?
Lainaus käyttäjältä: faeriedust - toukokuu 02, 2011, 09:01:58 IP
Just thinking....should the sizes in the admin avatars section be changed to any other setting outside of the default? Would that make any difference?
I will play around with the files I attached below to make sure I didnt do anything wrong... Right after I finish a paragraph of my essay. 8)
Hmm, I replaced my files and they seem to work as intended with default settings on a fresh new install of SMF.
http://rsnull.host56.com/smf/index.php?topic=4244.0
I guess I'll have to change back to the default sizes, if I can remember them now, and give that a shot. Thanks.
I just noticed that when I load a topic, the avatar comes in the size that I want it to, but then immediately changes back to the small one. Strange.
I've been helping faeriedust with this. I'm experiencing the same issue she is.
Seems to me the easiest way to do this would be to add a CSS class to moderator avatars and then just change the stylesheet. I'm not entirely sure where that would be set in SMF though. I was thinking post.template. Doesn't help that I'm great hacking other people's PHP, but I don't tend to write my own to be worth much on that front. :-P
Any updates on this? Do you still need assistance or have you been able to figure this out? :)