Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: vbgamer45 on July 30, 2010, 11:25:41 PM

Title: Default Avatar
Post by: vbgamer45 on July 30, 2010, 11:25:41 PM
Link to Mod (https://custom.simplemachines.org/mods/index.php?mod=2665)

Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=2665)


If a user's has not selected or uploaded any avatar, then this mod shows a standard avatar on post pages.


Which mod package to download?
People using SMF 1.x download package named - Default Avatar For SMF 1x.zip
People using SMF 2.x download package named - Default Avatar For SMF 2x.zip


Settings to enable and disable it can be found at

For smf 1.x
Features and Options » Layout and Options

For SMF 2.x
Modification Settings » Miscellaneous.


The default_avatar.png images is located in
Theme><YourTheme>/images/default_avatar.png

you can simply change it with the image you like to be as default avatar for your forum members.(Do remember to give that image file also same name "default_avatar.png"


Change Log

Version 2.3
- Extended support for other mods.
- Change in license
- Mod added on GitHub
- Big fixes


Version 2.2
- Removed the w3c validation error
- Add option to make avatars transparent after a user having default avatar logs out.
Credit for transparent avatars idea goes to Project Evolution (http://www.simplemachines.org/community/index.php?action=profile;u=164151)


Version 2.1 (SMF 2.0) and Version 1.4 (SMF 1.1.14)
- Mod updated for SMF 2.0 final and SMF 1.1.14
- License added to the mod
- Added 2 more features in mod
- Admin can add separate Default avatar images for users based on there genders (available for SMF 2.0 version only)


Version 2.0 * (SMF 2 RC4)
- Mod edits only source files, hence mod is compatible to all themes
- Now with the new version you can simply change the image path through settings panel only. You just have to place the image url and click save, the url image will become default image automatically.


Version 1.3 * (SMF 1.1.12) and  Version 1.4 * (SMF 2 RC4)
- Mod updated for SMF 1.1.12 and SMF 2.0 RC4


Version 1.2 * (SMF 1.1.11) and  version 1.3 * (SMF 2 RC3)
After uninstalling the mod image was not removed from images directory. This issue has been resolved now. Anyone facing the issue, simply install this version and uninstall it. Image from you images directory will be removed.


Version 1.1 * (SMF 1.1.11)
Added default avatar in Profile Header, Personal Messages and Profile Summary . Options are provided to enable and disable them also.


Version 1.2 * (SMF 2.0 RC3)
Added default avatar in Profile Header, Personal Messages and Profile Summary . Options are provided to enable and disable them also.


Mod released for SMF 1.1.11 also ;)


Version 1.1x
Removed extra slash from image transfer directory.(wasn't a major effect on mod , but still work should be done properly ;) )



FAQ's

1. How can I use default avatar in my mod?

Well to do this, you just need to place this code in your mod

if(function_exists('checkDefaultAvatar')) {
$context['user']['id']['avatar']['image'] = checkDefaultAvatar($context['buddies'][$uid]);
}



2. After putting the code my avatar images are gone?
While calling the function the data should be appended to the parameter which is carrying the avatar image. For e.g,
a) If you are using avatar image on '$context['user']['id']['avatar']' then use the above code as follow

if(function_exists('checkDefaultAvatar')) {
$context['user']['id']['avatar'] = checkDefaultAvatar($context['buddies'][$uid]);
}


b) If you are using avatar image on '$context['my_user']['id']['avatar']['img']' then use the above code as follow
if(function_exists('checkDefaultAvatar')) {
$context['my_user']['id']['avatar']['img'] = checkDefaultAvatar($context['buddies'][$uid]);
}




GitHub Link (https://github.com/Joker-SMF/SMF-Default-Avatar)

All images/css used in the mod falls under the license used below.

License
* This SMF Modification is subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this SMF modification except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
Title: Re: Default Avatar
Post by: frozenas on July 31, 2010, 08:14:37 AM
Hi. I'm not sure if this is supposed to be like that, just trying to help you with my barely new knowledge about PHP (Unfortunently most of the time i don't get support for plugins i'm trying to install, currently i need support for 3 of them. :/), but anyway, i've found this, when installing (double slashes):

./Themes/default/images//default_avatar.png

Although it works and it copies the image to /images folder. Don't know why it might be wrong, but it looks strange to me, lol. Sorry if it's alright, just trying to help.

Anyway, thanks for the modification, exatly what i needed. ;) Nice plugins you are doing.
Title: Re: Default Avatar
Post by: PurpleCrow on July 31, 2010, 10:21:53 AM
Your a star! Thank you ;D
Title: Re: Default Avatar
Post by: Joker™ on July 31, 2010, 10:32:08 AM
Quote from: frozenas on July 31, 2010, 08:14:37 AM
but anyway, i've found this, when installing (double slashes):

./Themes/default/images//default_avatar.png


Extra slashed removed , thanks for reporting it :) .

Thanks to both or you for such great comments ;D .
Title: Re: Default Avatar
Post by: ɔɔɔɔɔɔuɥoɾ on July 31, 2010, 01:15:25 PM
Nice mod JokerTM


Well done :)
Title: Re: Default Avatar
Post by: Joker™ on July 31, 2010, 02:59:41 PM
thank you :)
Title: Re: Default Avatar
Post by: Grim Line on July 31, 2010, 05:29:37 PM
Great mod even more useful to me than the avatar on register mod. Good job! :)

Would there be anyway to have a default avatar thats pulled from a URL though?
Title: Re: Default Avatar
Post by: Exochat on July 31, 2010, 06:31:27 PM
Great mod, read my mind as i was searching for something similar about 2 days ago and was disappointed nothing had been done!

Couple of small irrelevant things:

1) The instructions you have on the Mod Download page states Theme><YourTheme>default_avatar.png and you have missed out the IMAGES part of the directory.

It should read Theme><YourTheme>/images/default_avatar.png

Might save you a few support questions asking where it is located if you update your already simple and fantastic instructions to be correct :)

2) Do you know whether it will one day be compatible with such things as Dynamic Memberlist or Ultimate Profile, both of which display the users avatars and are not displaying your default one when its installed.

Otherwise, great Mod and should be included as standard on SMF forums!
Title: Re: Default Avatar
Post by: Joker™ on August 01, 2010, 02:47:59 AM
Quote from: Exochat on July 31, 2010, 06:31:27 PM
1) The instructions you have on the Mod Download page states Theme><YourTheme>default_avatar.png and you have missed out the IMAGES part of the directory.
It should read Theme><YourTheme>/images/default_avatar.png

Done :) , thanks for informing .

Quote2) Do you know whether it will one day be compatible with such things as Dynamic Memberlist or Ultimate Profile, both of which display the users avatars and are not displaying your default one when its installed.

Actually it is difficult to make a mod compatible to other mods , as there may be some other mods also , like these where you require default avatars.So, all i can say is you can take code from this mod and can add in those mods , as i tried to make the code as simple as possible .


Thanks for your comments :)
Title: Re: Default Avatar
Post by: arty5 on August 01, 2010, 09:33:10 AM
I was wondering if their was a mod for this and yea their is now thanx mate i will install it :D
Title: Re: Default Avatar
Post by: Joker™ on August 10, 2010, 01:38:25 PM
was sitting idle today and was thinking of adding some more features in it.Avatar is shown at 3 places

1.Header
2.Posts
3.Profile Summary

How about showing default avatar at all these places and adding permission for each membergroup that at which of these 3 places avatar should be shown. What do you guys say about this ? If you people find it interesting then only i'll start working on it.


Edit - Mod released for SMF 1.1.11 :). [Do report if you find any bug in it]
Title: Re: Default Avatar
Post by: Grim Line on August 15, 2010, 04:59:32 PM
I think thats a great idea Joker :)
Title: Re: Default Avatar
Post by: diamondred123 on August 15, 2010, 05:10:14 PM
Quote from: Nick; on August 15, 2010, 04:59:32 PM
I think thats a great idea Joker :)

i posted in the coders section for it and he made the mod :D
Title: Re: Default Avatar
Post by: Joker™ on August 15, 2010, 11:51:26 PM
Quote from: Nick; on August 15, 2010, 04:59:32 PM
I think thats a great idea Joker :)
Quote from: diamondred123 on August 15, 2010, 05:10:14 PM
Quote from: Nick; on August 15, 2010, 04:59:32 PM
I think thats a great idea Joker :)
i posted in the coders section for it and he made the mod :D

Right now i'm in no mood to upgrade it here , i might release it at my site if feel like working on it.
Title: Re: Default Avatar
Post by: Joker™ on August 26, 2010, 02:10:54 PM
Mod upgraded to version 1.2 for SMF 2.0 RC3.
Change log*

Added default avatar in Profile Header, Personal Messages and Profile Summary . Options are provided to enable and disable them also.

In next upgrade i'm planning to get the code out of template files and put them in source files ;). ( Above upgrade for SMF 1.1x will be done very soon. )
Title: Re: Default Avatar
Post by: Joker™ on August 26, 2010, 03:06:04 PM
Mod upgraded to version 1.1 for SMF 1.1.11
Change log*

Added default avatar in Profile Header, Personal Messages and Profile Summary . Options are provided to enable and disable them also.
Title: Re: Default Avatar
Post by: pugcabclub on August 27, 2010, 03:57:43 PM
Ive uplaoded the package, but cant find modifications>misc whereabouts is it please :-\ :-\ :-\ :-\
Title: Re: Default Avatar
Post by: Joker™ on August 27, 2010, 09:47:45 PM
Quote from: pugcabclub on August 27, 2010, 03:57:43 PM
Ive uplaoded the package, but cant find modifications>misc whereabouts is it please :-\ :-\ :-\ :-\
have you installed the mod ? as after installation you will be automatically redirected to the Modification Settings page .(which smf version are you using ?)
Title: Re: Default Avatar
Post by: pugcabclub on August 29, 2010, 03:08:00 PM
Im using smf 1.1.11

The package is showing as being installled
Title: Re: Default Avatar
Post by: Joker™ on August 29, 2010, 11:21:42 PM
in smf 1.1.11 option are in

admin panel >> Features and Options >> Layout and Options (but the mod should have redirected you automatically)
Title: Re: Default Avatar
Post by: pugcabclub on August 30, 2010, 08:35:56 AM
Sorted...Thank-you
Title: Re: Default Avatar
Post by: iPhoneDestek on September 15, 2010, 07:29:37 AM
translation in turkish




<file name="$languagedir/Modifications.turkish.php">
<operation>
  <search position="end" />
   <add><![CDATA[
// Default Avatar Mod translation by SirtLanVadisi.net
    $txt['enable_default_avatar_post'] = 'Konularda Varsayılan Avatarı etkinleştir';
    $txt['enable_default_avatar_pm'] = 'Özel Mesajlarda Varsayılan Avatarı etkinleştir';
    $txt['enable_default_avatar_profile'] = 'Profıl alanında Varsayılan Avatarı etkinleştir';
    $txt['enable_default_avatar_head'] = 'Başlık da Varsayılan Avatarı etkinleştir';
// End Default Avatarl Mod translation by SirtLanVadisi.net
   ]]></add>
</operation>
</file>
<file name="$languagedir/Modifications.turkish-utf8.php">
<operation>
  <search position="end" />
   <add><![CDATA[
// Default Avatar Mod translation by SirtLanVadisi.net
    $txt['enable_default_avatar_post'] = 'Konularda Varsayılan Avatarı etkinleÅŸtir';
    $txt['enable_default_avatar_pm'] = 'Özel Mesajlarda Varsayılan Avatarı etkinleÅŸtir';
    $txt['enable_default_avatar_profile'] = 'Profıl alanında Varsayılan Avatarı etkinleÅŸtir';
    $txt['enable_default_avatar_head'] = 'BaÅŸlık da Varsayılan Avatarı etkinleÅŸtir';
// End Default Avatarl Mod translation by SirtLanVadisi.net
   ]]></add>
</operation>
</file>



Title: Re: Default Avatar
Post by: iPhoneDestek on September 15, 2010, 07:31:34 AM
translatıon ın german by SirtLanVadisi.net






<file name="$languagedir/Modifications.german.php">
<operation>
  <search position="end" />
   <add><![CDATA[
// Default Avatar Mod translation by SirtLanVadisi.net
    $txt['enable_default_avatar_post'] = 'Default Avatar in Beiträgen ermöglichen';
    $txt['enable_default_avatar_pm'] = 'Default Avatar in Privat Nachrichten ermöglichen';
    $txt['enable_default_avatar_profile'] = 'Default Avatar in Profil ermöglichen';
    $txt['enable_default_avatar_head'] = 'Default Avatar in Kopfzeilen ermöglichen';
// End Default Avatarl Mod translation by SirtLanVadisi.net
   ]]></add>
</operation>
</file>
<file name="$languagedir/Modifications.german-utf8.php">
<operation>
  <search position="end" />
   <add><![CDATA[
// Default Avatar Mod translation by SirtLanVadisi.net
    $txt['enable_default_avatar_post'] = 'Default Avatar in Beiträgen ermöglichen';
    $txt['enable_default_avatar_pm'] = 'Default Avatar in Privat Nachrichten ermöglichen';
    $txt['enable_default_avatar_profile'] = 'Default Avatar in Profil ermöglichen';
    $txt['enable_default_avatar_head'] = 'Default Avatar in Kopfzeilen ermöglichen';
// End Default Avatar Mod translation by SirtLanVadisi.net
   ]]></add>
</operation>
</file>






Title: Re: Default Avatar
Post by: mirahalo on September 16, 2010, 07:30:15 PM
thanks you ®SirtLan   I supose this are for utf8 language right?   can this be used for iso also?
Title: Re: Default Avatar
Post by: iPhoneDestek on September 17, 2010, 05:53:15 AM
Quote from: 130860 on September 16, 2010, 07:30:15 PM
thanks you ®SirtLan   I supose this are for utf8 language right?   can this be used for iso also?



The translations are for both formats, as well as ISO and UTF8. So I translate on both formats
Title: Re: Default Avatar
Post by: Oya on September 17, 2010, 07:17:08 AM
teh first one wont be iso encoded by now it would have been saved here in utf8
Title: Re: Default Avatar
Post by: iPhoneDestek on September 17, 2010, 07:57:31 PM
Quote from: Oya on September 17, 2010, 07:17:08 AM
teh first one wont be iso encoded by now it would have been saved here in utf8



I use one myself forum with UTF-8 Language and MOD installations in ISO languages I need to convert the language to UTF-8. This is why I translate formats principle to both.
Title: Re: Default Avatar
Post by: Oya on September 17, 2010, 08:44:41 PM
yes but you posted it here in the post and its now fully in utf8 in that post
Title: Re: Default Avatar
Post by: Joker™ on October 31, 2010, 01:20:28 AM
Mod updated.

Change Log - version 1.2 * (SMF 1.1.11) and  version 1.3 * (SMF 2 RC3)
After uninstalling the mod image was not removed from images directory. This issue has been resolved now.

Anyone facing the issue, simply install this version and uninstall it. Image from you images directory will be removed.

Happy Halloween ;).
Title: Re: Default Avatar
Post by: Joker™ on November 14, 2010, 04:10:49 AM
Change Log - version 1.3 * (SMF 1.1.12) and  version 1.4 * (SMF 2 RC4)
- Mod updated for SMF 1.1.12 and SMF 2.0 RC4
Title: Re: Default Avatar
Post by: DoctorMalboro on November 15, 2010, 07:12:46 PM
The other someone asked about this mod and if it's possible to make it only for registered users. I share the code if anyone needs it:

./Themes/default/Display.template.php
search:
if (!empty($modSettings['enable_default_avatar_post']) && empty($options['show_no_avatars']) && empty($message['member']['avatar']['image']))

replace:
if (!empty($modSettings['enable_default_avatar_post']) && empty($options['show_no_avatars']) && empty($message['member']['avatar']['image']) && !$user_info['is_guest'])

./Themes/default/PersonalMessage.template.php
search:
if (!empty($modSettings['enable_default_avatar_pm']) && empty($options['show_no_avatars']) && empty($message['member']['avatar']['image']))

replace:
if (!empty($modSettings['enable_default_avatar_pm']) && empty($options['show_no_avatars']) && empty($message['member']['avatar']['image']) && !$user_info['is_guest'])

./Themes/default/index.template.php
search:
if (!empty($modSettings['enable_default_avatar_head']) && empty($context['user']['avatar']))

replace:
if (!empty($modSettings['enable_default_avatar_head']) && empty($context['user']['avatar']) && !$user_info['is_guest'])

./Themes/default/Profile.template.php
search:
if (!empty($modSettings['enable_default_avatar_profile']) && empty($context['member']['avatar']['image']))

replace:
if (!empty($modSettings['enable_default_avatar_profile']) && empty($context['member']['avatar']['image']) && !$user_info['is_guest'])
Title: Re: Default Avatar
Post by: Joker™ on November 15, 2010, 11:33:48 PM
Quote from: DoctorMalboro on November 15, 2010, 07:12:46 PM
The other someone asked about this mod and if it's possible to make it only for registered users. I share the code if anyone needs it:
I don't think default avatar's will be shown for guests  even without using the code you wrote above. Have you guys even tested it before modifying the code?

Edit - I enabled the mod, posted like guest and there was no avatar. (Am I missing something?). Also the $user_info also has to be declared in global.
Title: Re: Default Avatar
Post by: big red on November 28, 2010, 10:40:04 PM
  Hi Joker

  Got some test errors during install so i aborted and manually installed via the parsing instructions. It worked fine (default image showed in posts) for a few minutes but noticed images were not showing in a Simple Portal "Latest Member" block so i deleted the block and created a new one hoping that would work. But now your mod is no longer working. Firefox shows no default image and chrome shows the broken image symbol. I have deleted the browser/forum caches, re-checked using the parser and everything seems to be there. Even re-uploaded your default image again but still not working.

   Anyone have a clue what's going on here?? Anyone using Joker's mod with the latest versions of SMF & SP with a "latest member" block successfully???
Title: Re: Default Avatar
Post by: Joker™ on November 29, 2010, 12:51:56 AM
Quote from: big red on November 28, 2010, 10:40:04 PM
  Hi Joker

  Got some test errors during install so i aborted and manually installed via the parsing instructions. It worked fine (default image showed in posts) for a few minutes but noticed images were not showing in a Simple Portal "Latest Member" block so i deleted the block and created a new one hoping that would work. But now your mod is no longer working. Firefox shows no default image and chrome shows the broken image symbol. I have deleted the browser/forum caches, re-checked using the parser and everything seems to be there. Even re-uploaded your default image again but still not working.

   Anyone have a clue what's going on here?? Anyone using Joker's mod with the latest versions of SMF & SP with a "latest member" block successfully???
Simple portal block will not be containing the default avatar mod code, hence the avatar was not shown in it.
Title: Re: Default Avatar
Post by: big red on November 29, 2010, 11:18:19 AM
Quote from: Joker™ on November 29, 2010, 12:51:56 AM
Quote from: big red on November 28, 2010, 10:40:04 PM
  Hi Joker

  Got some test errors during install so i aborted and manually installed via the parsing instructions. It worked fine (default image showed in posts) for a few minutes but noticed images were not showing in a Simple Portal "Latest Member" block so i deleted the block and created a new one hoping that would work. But now your mod is no longer working. Firefox shows no default image and chrome shows the broken image symbol. I have deleted the browser/forum caches, re-checked using the parser and everything seems to be there. Even re-uploaded your default image again but still not working.

   Anyone have a clue what's going on here?? Anyone using Joker's mod with the latest versions of SMF & SP with a "latest member" block successfully???
Simple portal block will not be containing the default avatar mod code, hence the avatar was not shown in it.

   Ok - that's fine. But how come it was working for a few minutes and now doesn't?? Could the latest member block have corrupted your mod somehow?? The latest member block was showing avatars (non default) and now it isn't.
Title: Re: Default Avatar
Post by: Joker™ on November 29, 2010, 01:30:43 PM
Quote from: big red on November 29, 2010, 11:18:19 AM
Quote from: Joker™ on November 29, 2010, 12:51:56 AM
Quote from: big red on November 28, 2010, 10:40:04 PM
  Hi Joker

  Got some test errors during install so i aborted and manually installed via the parsing instructions. It worked fine (default image showed in posts) for a few minutes but noticed images were not showing in a Simple Portal "Latest Member" block so i deleted the block and created a new one hoping that would work. But now your mod is no longer working. Firefox shows no default image and chrome shows the broken image symbol. I have deleted the browser/forum caches, re-checked using the parser and everything seems to be there. Even re-uploaded your default image again but still not working.

   Anyone have a clue what's going on here?? Anyone using Joker's mod with the latest versions of SMF & SP with a "latest member" block successfully???
Simple portal block will not be containing the default avatar mod code, hence the avatar was not shown in it.

   Ok - that's fine. But how come it was working for a few minutes and now doesn't?? Could the latest member block have corrupted your mod somehow?? The latest member block was showing avatars (non default) and now it isn't.
I have never used portal system, so no idea about this one.
Title: Re: Default Avatar
Post by: live627 on November 29, 2010, 08:54:46 PM
Joker, this mod can and should be rewritten to include zero theme edits. Doing so will bring tremendous rewards: Farting around with themes becomes a thing of the past; if you do it correctly, you can suddenly get the default avatar to display just about anywhere (portal systems included);  you won't need to adjust the code to keep compatibility up (The code I have in mind did not change a bit between RC releases and I think the 1.1 equivalent is almost the same).
Title: Re: Default Avatar
Post by: Joker™ on November 29, 2010, 11:59:10 PM
Quote from: live627 on November 29, 2010, 08:54:46 PM
Joker, this mod can and should be rewritten to include zero theme edits. Doing so will bring tremendous rewards: Farting around with themes becomes a thing of the past; if you do it correctly, you can suddenly get the default avatar to display just about anywhere (portal systems included);  you won't need to adjust the code to keep compatibility up (The code I have in mind did not change a bit between RC releases and I think the 1.1 equivalent is almost the same).
I know Load.php will do the most of the trick, thanks for the suggestion. If i get time in upcoming days I'll make it a non-template edit mod ;).
Title: Re: Default Avatar
Post by: big red on December 03, 2010, 03:04:34 AM
  Figured out the issue Joker

I installed via the "parser" and your last instruction there was
QuoteMove the included file "default_avatar.png" to "./Themes/default/images".

    Now in proper directory and works fine.

           
Title: Re: Default Avatar
Post by: Joker™ on December 10, 2010, 12:56:45 PM
Quote from: live627 on November 29, 2010, 08:54:46 PM
Joker, this mod can and should be rewritten to include zero theme edits. Doing so will bring tremendous rewards: Farting around with themes becomes a thing of the past; if you do it correctly, you can suddenly get the default avatar to display just about anywhere (portal systems included);  you won't need to adjust the code to keep compatibility up (The code I have in mind did not change a bit between RC releases and I think the 1.1 equivalent is almost the same).
Upgraded the mod for SMF 2.0 branch with some more options. Hope you guys will like it ;).
Title: Re: Default Avatar
Post by: Wally. on December 17, 2010, 01:05:14 PM
Hey Joker I've been using this mod for a while (thanks by the way) and I just updated my system and this mod. However, it doesn't display the avatars in my portal blocks. I was under the impression that the new version worked with simple portal was I incorrect or do I have some sort of install issue?
Title: Re: Default Avatar
Post by: live627 on December 17, 2010, 01:22:45 PM
Did you download    Default Avatar 2.0 (Source) For SMF 2x.zip
Title: Re: Default Avatar
Post by: Wally. on December 17, 2010, 02:09:22 PM
Yep thats the one I installed.
Title: Re: Default Avatar
Post by: live627 on December 17, 2010, 10:45:18 PM
I'd assume you enabled the mod...

If so, then SP didn't call from the centralised member functions since that is only what this mod modifies. Check with the folks on SP.net since I could be wrong on it. I haven't looked at their code.
Title: Re: Default Avatar
Post by: Wally. on December 23, 2010, 09:08:45 AM
Here is the response that I got from the SP staff:

QuoteHave a look at function sp_userInfo in PortalBlocks.php

You can see that, to get a registered users's member info, it does

  loadMemberData($user_info['id']);
  loadMemberContext($user_info['id']);
  $member_info = $memberContext[$user_info['id']];

and then it uses

  if (!empty($member_info['avatar']['image']))
   echo '
         ', $member_info['avatar']['image'], '<br /><br />';

to display the image.

If the mod does not stuff the default avatar image into $memberContext[$user_info['id']['avatar']['image'], then you can copy a little of the mod's logic in this spot --- else echo $default_avatar_link; sort of thing.

So at this point am I correct in assuming that this means there was an issue with the install somewhere?
Title: Re: Default Avatar
Post by: Joker™ on January 01, 2011, 02:03:32 AM
Isn't my load.php code loading ($memberContext[$user]['avatar']['image']) ?

Please have a look at the code which this mod is modifying in Load.php.
Title: Re: Default Avatar
Post by: Wally. on January 01, 2011, 08:52:17 PM
I checked it and this is what was there:

if ($memberContext[$user]['avatar']['image'] == '' && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif ($memberContext[$user]['avatar']['image'] == '' && !empty($modSettings['enable_default_avatar']) && empty($modSettings['default_avatar_url']))
$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '',
'url' => '',
);
// Are we also loading the members custom fields into context?
Title: Re: Default Avatar
Post by: Joker™ on January 01, 2011, 11:47:51 PM
so isn't this much code is sufficient from my part

$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => '',
'url' => '',
);
Title: Re: Default Avatar
Post by: Wally. on January 02, 2011, 11:12:14 PM
Quote from: Joker™ on January 01, 2011, 11:47:51 PM
so isn't this much code is sufficient from my part

I'm sorry Joker I'm not sure what you meant here.
Title: Re: Default Avatar
Post by: Joker™ on January 09, 2011, 01:35:34 AM
Yeyy some vacations for me at last, if i get a chance I'll install SP by today only and will try to look into the problem.
Title: Re: Default Avatar
Post by: Joker™ on January 09, 2011, 11:41:18 PM
Quote from: Wally. on January 02, 2011, 11:12:14 PM
Quote from: Joker™ on January 01, 2011, 11:47:51 PM
so isn't this much code is sufficient from my part

I'm sorry Joker I'm not sure what you meant here.
The code I showed you above your post,

$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => '',
'url' => '',
);


sums up like,

$memberContext[$user]['avatar']['name']
$memberContext[$user]['avatar']['image'] , and so on.

which I think is required for SP.

I installed simple portal, since I'm a real noob in using this portals, can you tell me which(and how) sort of portal block you have created in which this mod(default avatar) hasn't worked properly.
Title: Re: Default Avatar
Post by: Wally. on January 10, 2011, 08:04:18 AM
Sure, I'm using the Top Poster Block (set to display the top 10 posters for the month) and the Board News Block. Top Poster is on the top left side of this page http://www.wallynet.org/forum/index.php and Board News is below the gallery pics.

You'll be able to see the blank slots in the top left block - those are people with default avatars.

In the Board News area the avatar on the right would be empty if the thread was started by someone with a default avatar.

And all of that was set up through "Administration Center > Simple Portal > Blocks > Block List".

(I've attached a screen cap below showing the blanks next to Donuticus, Ari and Mister iLose)

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi654.photobucket.com%2Falbums%2Fuu268%2FWally_038%2Fscreencap-1.jpg&hash=8a222644544ead8ea53dc459e5d277bc126768d7)
Title: Re: Default Avatar
Post by: Joker™ on January 14, 2011, 09:52:01 AM
OMG, i don't know how I forgot to reply to you :o.

Try these codes (after installing the Default avatar mod, make these changes).

In Load.php
Find:

if ($memberContext[$user]['avatar']['image'] == '' && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif ($memberContext[$user]['avatar']['image'] == '' && !empty($modSettings['enable_default_avatar']) && empty($modSettings['default_avatar_url']))
$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '',
'url' => '',
);



Replace it with:

if ($memberContext[$user]['avatar']['image'] == '' && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);

elseif ($memberContext[$user]['avatar']['image'] == '' && !empty($modSettings['enable_default_avatar']) && empty($modSettings['default_avatar_url']))
$memberContext[$user]['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'url' => '',
);



In Subs.php
Find:

if (empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);

if (empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '',
'url' => '',
);


Replace it with:

if (empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);

if (empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'url' => '',
);

Title: Re: Default Avatar
Post by: Wally. on January 14, 2011, 08:46:53 PM
Quote from: Joker™ on January 14, 2011, 09:52:01 AM
OMG, i don't know how I forgot to reply to you :o.

No worries.  :)

I made the change to both the sub and load files but it didn't seem to make a difference. Just to make sure I didn't do anything wrong the 'href' lines were the only things that changed weren't they?
Title: Re: Default Avatar
Post by: Joker™ on January 14, 2011, 10:04:06 PM
Quote from: Wally. on January 14, 2011, 08:46:53 PM
I made the change to both the sub and load files but it didn't seem to make a difference. Just to make sure I didn't do anything wrong the 'href' lines were the only things that changed weren't they?
Yeah, as SP is calling for avatars using ['avatar']['href'].

I'll look into this again.
Title: Re: Default Avatar
Post by: Joker™ on January 15, 2011, 05:01:15 AM
I even tried with this, but it result was negative.

In Sources\PortalBlock.php
Find:
if (empty($members))
{
echo '
', $txt['error_sp_no_members_found'];
return;


Before:
if (empty($members['avatar']['image']) && !empty($modSettings['enable_default_avatar']))
{ $members['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);
}
Title: Re: Default Avatar
Post by: Wally. on January 17, 2011, 07:45:11 PM
Regardless, thanks for giving it a go.

:)
Title: Re: Default Avatar
Post by: Yankee on April 26, 2011, 11:53:12 PM
Well, here's a question for ya Joker:

In the manual install instructions for SMF 1.1.13 to this mod you refer to a file called ./Sources/ManageSettings.php that needs to be edited, but there is no file by that name. At least I can't find it.

Is this a typo or have my brain just turned into slush?
Title: Re: Default Avatar
Post by: live627 on April 27, 2011, 12:14:29 AM
SMF 2.x only
Title: Re: Default Avatar
Post by: Yankee on April 27, 2011, 01:11:01 AM
Quote from: live627 on April 27, 2011, 12:14:29 AM
SMF 2.x only

Well, then someone seriously needs to edit the damn instructions.

Thanx anyway  ;)
Title: Re: Default Avatar
Post by: live627 on April 27, 2011, 01:22:27 AM
No one needs to edit anything. i just checked the page and the package. The instructions are in plain sight. It's not my fault if nobody reads them.
Title: Re: Default Avatar
Post by: Joker™ on April 27, 2011, 03:17:29 PM
Quote from: Yankee on April 26, 2011, 11:53:12 PM
Well, here's a question for ya Joker:

In the manual install instructions for SMF 1.1.13 to this mod you refer to a file called ./Sources/ManageSettings.php that needs to be edited, but there is no file by that name. At least I can't find it.

Is this a typo or have my brain just turned into slush?
Now I've got a question for ya

Have you read this on mod page?

QuoteWhich mod package to download?
People using SMF 1.1.12 download package named - Default Avatar 1.3 For SMF 1x.zip
Title: Re: Default Avatar
Post by: bassbass on June 07, 2011, 02:25:29 AM
ho do i get rid of the scroll bar?!  see attached photo...
Title: Re: Default Avatar
Post by: live627 on June 07, 2011, 02:27:32 AM
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.katzy.dsl.pipex.com%2FSMF%2Fwhichtheme.gif&hash=0a9eb3a25c4c8469b59e43499dee38ca9090a48e)
Title: Re: Default Avatar
Post by: bassbass on June 07, 2011, 02:41:35 PM
default  theme.
Title: Re: Default Avatar
Post by: Joker™ on June 07, 2011, 03:13:55 PM
- SMF version?
- Forum link?
- Browser?
- Resolution?
Title: Re: Default Avatar
Post by: bassbass on June 07, 2011, 05:30:19 PM
sorry!

1.1.13
www.gtcmusic.com
IE and FF
i don't know what you mean by resolution!
Title: Re: Default Avatar
Post by: live627 on June 07, 2011, 06:18:41 PM
screen size
Title: Re: Default Avatar
Post by: bassbass on June 07, 2011, 08:30:28 PM
i don't what that have to do with adjusting the area for the avatar, but my screen size is 22" 1680x1050
Title: Re: Default Avatar
Post by: live627 on June 07, 2011, 08:59:36 PM
Me neither but the mod author requested it :P

Did you try a smaller image? I think the image might be too long thus causing overflow which brings up a scroll bar
Title: Re: Default Avatar
Post by: bassbass on June 08, 2011, 02:25:32 AM
yes i did! 
Title: Re: Default Avatar
Post by: Joker™ on June 08, 2011, 02:30:49 AM
http://www.gtc-music1.com/forum/index.php?topic=5822.0 << No scroll bar was present in this thread, have you made any changes lately?
Title: Re: Default Avatar
Post by: live627 on June 08, 2011, 03:38:31 AM
Text size? Operating system?

Did you try normal text size?
Title: Re: Default Avatar
Post by: yakyakyak on June 08, 2011, 04:30:13 AM
Thank you for your work on this modification - it's a lovely addition

We are also using the Transparent Offline Avatars mod
http://custom.simplemachines.org/mods/index.php?mod=2995

however, the default avatar is unaffected with the transparency when the member is offline.

i have attempted to get support from the Transparent Offline Avatars thread but to no avail so far.

Any ideas welcome

thanks

yak
Title: Re: Default Avatar
Post by: Joker™ on June 08, 2011, 08:07:34 AM
Quote from: live627 on June 08, 2011, 03:38:31 AM
Text size? Operating system?

Did you try normal text size?
was that for me? If yes then,

- Text size - Normal
- OS - Windows 7 (why you asked this, lol)



Quote from: yakyakyak on June 08, 2011, 04:30:13 AM
Thank you for your work on this modification - it's a lovely addition

We are also using the Transparent Offline Avatars mod
http://custom.simplemachines.org/mods/index.php?mod=2995

however, the default avatar is unaffected with the transparency when the member is offline.

i have attempted to get support from the Transparent Offline Avatars thread but to no avail so far.

Any ideas welcome

thanks

yak
That would require to import the JS from that mod into this mod. TBH I've a pretty poor knowledge of it, so this take seems to be out of my scope :P.
Title: Re: Default Avatar
Post by: yakyakyak on June 08, 2011, 08:55:56 AM
ok thanks for the fast reply but it's a shame as the two mods are an ideal marriage imho

Title: Re: Default Avatar
Post by: bassbass on June 08, 2011, 02:40:25 PM
Quote from: live627 on June 08, 2011, 03:38:31 AM
Text size? Operating system?

Did you try normal text size?

yes its normal.  i guess no help on this one, i just have to let my developers fix it!
Title: Re: Default Avatar
Post by: Joker™ on June 08, 2011, 03:01:36 PM
Quote from: bassbass on June 08, 2011, 02:40:25 PM
yes its normal.  i guess no help on this one, i just have to let my developers fix it!
Can you point me to the thread where scroll bar is appearing?
Title: Re: Default Avatar
Post by: bassbass on June 09, 2011, 04:17:02 PM
http://www.gtc-music1.com/forum/index.php?topic=4207.msg92544#msg92544 (http://www.gtc-music1.com/forum/index.php?topic=4207.msg92544#msg92544)
Title: Re: Default Avatar
Post by: bassbass on June 09, 2011, 04:20:28 PM
just checked it on FF and it works fine, i guess its my browser, i use IE what other setting i can look at?
Title: Re: Default Avatar
Post by: bassbass on June 09, 2011, 04:25:10 PM
ahhh, fixed it.  in IE>Tools and selected Compatibility View!
Title: Re: Default Avatar
Post by: bassbass on June 09, 2011, 04:27:15 PM
oops, i guess not!  now the member avatar has scroll bars!
Title: Re: Default Avatar
Post by: Joker™ on June 09, 2011, 04:38:04 PM
For me in compatibility view there are no scroll bars, but in normal view there the scroll bars for default avatars.
Title: Re: Default Avatar
Post by: Joker™ on June 17, 2011, 04:39:17 PM
Mod updated with a new feature for SMF 2.0, hope you people like it


Version 2.1 (SMF 2.0) and Version 1.4 (SMF 1.1.14)
- Mod updated for SMF 2.0 final and SMF 1.1.14
- License added to the mod
- Added 2 more features in mod
- Admin can add separate Default avatar images for users based on there genders (available for SMF 2.0 version only)


I really don't why I personally love this mod so much :).
Title: Re: Default Avatar
Post by: jaisi on June 23, 2011, 03:52:10 PM
i have just install this mod and my forum gose down 500 internal Error  now please help me how to get back my forum online i have change free files lord.php and subs.php and modification.english.php but still showing 500 internale Error please check here is my php files
Title: Re: Default Avatar
Post by: Joker™ on June 23, 2011, 03:55:19 PM
Quote from: jaisi on June 23, 2011, 03:52:10 PM
i have just install this mod and my forum gose down 500 internal Error  now please help me how to get back my forum online i have change free files lord.php and subs.php and modification.english.php but still showing 500 internale Error please check here is my php files
If you have removed the mod codes from the files what do you expect me to check in them?

Have you contacted your host yet?
Title: Re: Default Avatar
Post by: jaisi on June 23, 2011, 04:02:22 PM
yes i have replace new files but error is stil showing. and i have contact with host team  he said no issue in our end please check you application.

please jocker bhai help me out yaar i'am really suck
Title: Re: Default Avatar
Post by: Joker™ on June 23, 2011, 04:14:06 PM
I've seen your files once again and they seem to be in perfect shape to me.

Why "500 internal Error (http://www.google.co.in/search?client=opera&rls=en&q=500+internal+Error&sourceid=opera&ie=utf-8&oe=utf-8&channel=suggest)" occur.

You can make a search on SMF too, but mostly it's a host side issue.
Title: Re: Default Avatar
Post by: snooks on June 23, 2011, 04:50:02 PM
Joker,
I am running the other version 2.0 and working great i thought i would update this to 2.1 SMF20 but came across this when trying to uninstall http://imageshack.us/photo/my-images/849/unledgjo.jpg/ any suggestions on what to do please stay with old version or how to fix to be able to upgrade

thanks and great mod btw
Title: Re: Default Avatar
Post by: Joker™ on June 23, 2011, 05:14:02 PM
I don't remember exactly but Sources/ManageSettings.php must be having this code

array('check', 'enable_default_avatar'),
array('text', 'default_avatar_url', 50, 'subtext' => $txt['default_avatar_path']),


If thats the case, then

- Uninstall the mod
- Open the above mentioned file (Make backup of the file)
- Remove the above mentioned code from the file
- Save the file and you are done ;).
Title: Re: Default Avatar
Post by: snooks on June 24, 2011, 01:56:50 AM
Quote from: Joker™ on June 23, 2011, 05:14:02 PM
I don't remember exactly but Sources/ManageSettings.php must be having this code

array('check', 'enable_default_avatar'),
array('text', 'default_avatar_url', 50, 'subtext' => $txt['default_avatar_path']),


If thats the case, then

- Uninstall the mod
- Open the above mentioned file (Make backup of the file)
- Remove the above mentioned code from the file
- Save the file and you are done ;).

Sorry i am very new to these things, so let me get this right i uninstall first even though i have this error ? then follow your steps

Have i removed it correctly see code below i have already removed it but making sure its done correctly very new to this editing hope you don't mind me asking you to check

// If you have a general mod setting to add stick it here.
function ModifyGeneralModSettings($return_config = false)
{
global $txt, $scripturl, $context, $settings, $sc, $modSettings;

$config_vars = array(
// Mod authors, add any settings UNDER this line. Include a comma at the end of the line and don't remove this statement!!

array('check', 'enable_join_date_post'),
array('check', 'enable_member_location_post'),
array('check', 'enable_join_date_pm'),
array('check', 'enable_member_location_pm'),
'',
// SMFHacks.com Contact Page
array('text', 'smfcontactpage_email'),

);

// Make it even easier to add new settings.
call_integration_hook('integrate_general_mod_settings', array(&$config_vars));

if ($return_config)
return $config_vars;


thanks
Title: Re: Default Avatar
Post by: Joker™ on June 24, 2011, 02:16:34 AM
- First check the file I've mentioned before for the code.
- If the code is there in the file
|-- Make back up of the the mod related files first
|-- Uninstall the mod
|-- Remove the code from that file

Surf the forum for a while and see if everything alright or not. If everything went as per plan go and install the new package.

Now you owe me a party :P.
Title: Re: Default Avatar
Post by: snooks on June 24, 2011, 02:23:56 AM
LOL work right now but will attempt this surgery afterwards :)
Title: Re: Default Avatar
Post by: Joker™ on June 24, 2011, 02:30:36 AM
Quote from: snooks on June 24, 2011, 02:23:56 AM
LOL work right now but will attempt this surgery afterwards :)
Call Dr. Joker if you require any assistance ;D.
Title: Re: Default Avatar
Post by: snooks on June 24, 2011, 11:40:49 AM
Upgraded and no problems woop ima getting good at text surgery :) cheers joker for all your help i am sure we will meet again lol
Title: Re: Default Avatar
Post by: wynnyelle on September 07, 2011, 04:34:35 AM
I have uploaded this but cannot get it to install. Running 2.0 RC 3. Is there anything I can do to get it working?
Title: Re: Default Avatar
Post by: Joker™ on September 07, 2011, 06:12:22 AM
Quote from: Groovystar on September 07, 2011, 04:34:35 AM
I have uploaded this but cannot get it to install. Running 2.0 RC 3. Is there anything I can do to get it working?
Upgrade to SMF 2.0 ;).
Title: Re: Default Avatar
Post by: wynnyelle on September 07, 2011, 07:52:55 PM
And do what with over $1,000 worth of custom mods and themes? It's just not an option right now, I'm sorry. Is there a way to customise this mod to my site's needs? I will pay, because the alternative is paying a LOT more.
Title: Re: Default Avatar
Post by: Joker™ on September 08, 2011, 06:32:36 AM
Quote from: Groovystar on September 07, 2011, 07:52:55 PM
And do what with over $1,000 worth of custom mods and themes? It's just not an option right now, I'm sorry. Is there a way to customise this mod to my site's needs? I will pay, because the alternative is paying a LOT more.

So you want me to help you out with this mod on RC3 having security holes? What if someone tries to exploit them, I don't think those 1000$ will come handy at that moment.


I'd suggest you to upgrade to SMF 2.0 first and if you find it difficult hire some web developer to complete the task for you.
Title: Re: Default Avatar
Post by: wynnyelle on September 13, 2011, 03:57:26 PM
I am talking to a programmer now about the problems. I still can't get the avatars to install though.
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 12:36:30 PM
I am running 2.0 - When I try to install this mod it gives me this error: The package you are trying to download or install is either corrupt or not compatible with this version of SMF.

I did use this on 2.0 RC4 and it worked fine.
Title: Re: Default Avatar
Post by: TheListener on September 19, 2011, 12:44:37 PM
Install the mod as normal.

Below the mod list you should see an advance link.

Click there then in the box put 2.0 RC4

once done then remember to change back to 2.0

Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 12:46:56 PM
It doesn't give me that option. Just displays that error message, not even a back button underneath it. I know the option you are on about as I've used it previously.
Title: Re: Default Avatar
Post by: TheListener on September 19, 2011, 12:48:02 PM
Go to the page which shows the list of mods on the forum.
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 12:48:56 PM
Default Avatar  2.1  [ List Files ][ Delete ]

That is what it's showing for that mod.
Title: Re: Default Avatar
Post by: TheListener on September 19, 2011, 12:50:37 PM
Try reading what I said.

The BOTTOM of the mod list
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 12:53:14 PM
Sorry, I mis-read what you said. I've got it installed now. Thanks.
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 12:59:12 PM
Sorry to be a pain in the backside, but the avatar isn't actually showing up.
Title: Re: Default Avatar
Post by: TheListener on September 19, 2011, 01:03:06 PM
Link to forum?

Have you checked your default theme?

Errors on the install?
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 01:04:29 PM
www.totaltechtalk.co.uk

The image is in the theme folder that I am using, it's also in the core and default images folder.

No.
Title: Re: Default Avatar
Post by: TheListener on September 19, 2011, 01:09:35 PM
Sorry bud but this is beyond me now.

:(
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 01:11:17 PM
Lol, bit strange. Thanks anyway. :D
Title: Re: Default Avatar
Post by: Joker™ on September 19, 2011, 05:27:37 PM
Quote from: Jue on September 19, 2011, 12:36:30 PM
I am running 2.0 - When I try to install this mod it gives me this error: The package you are trying to download or install is either corrupt or not compatible with this version of SMF.

I did use this on 2.0 RC4 and it worked fine.
Tried to install this package "Default Avatar For SMF 2x.zip"?
Title: Re: Default Avatar
Post by: Jue on September 19, 2011, 05:56:05 PM
That's the one I used.
Title: Re: Default Avatar
Post by: Joker™ on September 20, 2011, 07:36:48 AM
Quote from: Jue on September 19, 2011, 12:36:30 PM
I am running 2.0 - When I try to install this mod it gives me this error: The package you are trying to download or install is either corrupt or not compatible with this version of SMF.
Has the same thing happened with other mods also while installing them on SMF 2.0, as I've just installed this mod on SMF 2.0 and it got installed flawlessly.

What are the errors in the error log in admin panel regarding the installation of this mod?

Quote from: Jue on September 19, 2011, 01:04:29 PM
www.totaltechtalk.co.uk

The image is in the theme folder that I am using, it's also in the core and default images folder.

No.
I think you are using some other theme then default & core theme. Try placing the avatar image in
themes\<theme you are using>\images\


I'll try to make the mod more generalize so that it can pick images from default theme itself ;).
Title: Re: Default Avatar
Post by: Joker™ on September 30, 2011, 06:21:09 PM
Mod updated

Quote from: Joker™ on September 20, 2011, 07:36:48 AM
I'll try to make the mod more generalize so that it can pick images from default theme itself ;).
Done.


Quote from: yakyakyak on June 08, 2011, 04:30:13 AM
however, the default avatar is unaffected with the transparency when the member is offline.
And done ;).
Title: Re: Default Avatar
Post by: Inti31 on September 30, 2011, 07:36:42 PM
nice work - works fine with 2.0.1

here is the german, also german-utf8 translation


<file name="$languagedir/Modifications.german-utf8.php">
<operation>
<search position="end" />
<add><![CDATA[
$txt['enable_default_avatar'] = 'Aktiviere Standard Avatar';
$txt['default_male_avatar_url'] = 'Bilddateipfad - m&#228;nnliche Mitglieder';
$txt['default_female_avatar_url'] = 'Bilddateipfad - weibliche Mitglieder';
$txt['default_avatar_url'] = 'Bilddateipfad des Standard Avatarsymbols';
$txt['default_avatar_path'] = '(Sollte keine Angabe gemacht werden, wird das Standardbild angezeigt)';
$txt['default_avatar_opacity'] = 'Transparenz des Standard Avatars einschalten, wenn Mitglied sich ausloggt bzw. offline ist';
]]></add>
</operation>
</file>


cheers Inti31
Title: Re: Default Avatar
Post by: snooks on October 18, 2011, 03:27:29 PM
Quote from: Joker™ on June 24, 2011, 02:30:36 AM
Quote from: snooks on June 24, 2011, 02:23:56 AM
LOL work right now but will attempt this surgery afterwards :)
Call Dr. Joker if you require any assistance ;D.

Hi joker

I wanted to upgrade to 2.2 but when i went to uninstall i had a few test failed errors so i am scared to carry on lol, what should i do to upgrade please do i have to replace the codes only to add them back after a upgrade ?

thank you
Title: Re: Default Avatar
Post by: TheListener on October 18, 2011, 03:29:17 PM
Quotedo i have to replace the codes only to add them back after a upgrade ?

If necessary yes.
Title: Re: Default Avatar
Post by: Joker™ on October 18, 2011, 07:09:42 PM
Quote from: snooks on October 18, 2011, 03:27:29 PM
Hi joker

I wanted to upgrade to 2.2 but when i went to uninstall i had a few test failed errors so i am scared to carry on lol, what should i do to upgrade please do i have to replace the codes only to add them back after a upgrade ?

thank you

I think you mean you are upgrading to SMF 2.0.1?
The mod will be uninstalled itself if you are making a large upgrade. When you will upload the new files all the previous mod code will be removed itself.

After the upgrade simply install the mod.

Haz I missed something :P?
Title: Re: Default Avatar
Post by: snooks on October 19, 2011, 08:25:37 AM
No joker i am already on SMF 201 but my default avatar is 2.1 and new version is 2.2 but when i try to uninstall 2.1 to install 2.2 i have a few test failed errors
hope that explains it better

thanks
Title: Re: Default Avatar
Post by: Joker™ on October 19, 2011, 10:24:20 AM
Quote from: snooks on October 19, 2011, 08:25:37 AM
No joker i am already on SMF 201 but my default avatar is 2.1 and new version is 2.2 but when i try to uninstall 2.1 to install 2.2 i have a few test failed errors
hope that explains it better

thanks
If you are comfortable with manual edits, go to the packages directory using ftp. Download a zip file in there named something as "Default Avatar For SMF 2x.zip".

Attach that zip file here and do mention that while your uninstallation attempt which files have showed you errors.
Title: Re: Default Avatar
Post by: snooks on October 20, 2011, 11:35:10 AM
No joker im not comfortable with more than one edit sorry to say very scared to mess things up  :-[
Ive attached the file you asked and here is those test failed errors many thanks for your support joker

./Sources/Subs.php - find

// Default avatar mod starts here.
if(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && ($context['user']['gender'] == '1') && !empty($modSettings['default_male_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_male_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && ($context['user']['gender'] == '2') && !empty($modSettings['default_female_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_female_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '',
'url' => '',
);
// Default avatar mod ends.

// Figure out how long they've been logged in.


replace with -

      // Figure out how long they've been logged in.
=================


./Sources/ManageSettings.php - FIND

$config_vars = array(
// Mod authors, add any settings UNDER this line. Include a comma at the end of the line and don't remove this statement!!
array('check', 'enable_default_avatar'),
array('text', 'default_male_avatar_url'),
array('text', 'default_female_avatar_url'),
array('text', 'default_avatar_url', 50, 'subtext' => $txt['default_avatar_path']),


replace with -

$config_vars = array(
// Mod authors, add any settings UNDER this line. Include a comma at the end of the line and don't remove this statement!!
==========================


is that what you mean joker ?
Title: Re: Default Avatar
Post by: Joker™ on October 20, 2011, 12:02:45 PM
From the above post of yours I understand that you are having issues with following files while uninstalling the mod

- Subs.php
- ManageSettings.php

If that's the case, then make a back of both of the files somewhere on your PC before editing them


Sources/Subs.php
Code (Find and remove) Select

// Default avatar mod starts here.
if(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && ($context['user']['gender'] == '1') && !empty($modSettings['default_male_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_male_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && ($context['user']['gender'] == '2') && !empty($modSettings['default_female_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_female_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '',
'url' => '',
);
// Default avatar mod ends.



Sources/ManageSettings.php
Code (Find and remove) Select
array('check', 'enable_default_avatar'),
array('text', 'default_male_avatar_url'),
array('text', 'default_female_avatar_url'),
array('text', 'default_avatar_url', 50, 'subtext' => $txt['default_avatar_path']),



Ohh and I placed the code in your post in [ code ] [ /code] tags.
Title: Re: Default Avatar
Post by: T3CHN0 on October 23, 2011, 09:51:26 AM
thankyou for such a great mod, works better then the other 2 default/generic avatar mods.
only problem is FireFox 7 doesn't recognize download names with spaces and your mod will download as
""default"" and not ""Default Avatar For SMF 2X.zip"" if you could rename your download file to Default_Avatar_For_SMF_2X.zip
it will stop others asking later on why there is no file extension on the download.
Maybe FireFox will fix there bug maybe not but to save everyones time. best to rename the download I think.

Cheers
Title: Re: Default Avatar
Post by: snooks on October 23, 2011, 01:17:12 PM
Quote from: Joker™ on October 20, 2011, 12:02:45 PM
From the above post of yours I understand that you are having issues with following files while uninstalling the mod

- Subs.php
- ManageSettings.php

If that's the case, then make a back of both of the files somewhere on your PC before editing them


Sources/Subs.php
Code (Find and remove) Select

// Default avatar mod starts here.
if(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && ($context['user']['gender'] == '1') && !empty($modSettings['default_male_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_male_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && ($context['user']['gender'] == '2') && !empty($modSettings['default_female_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_female_avatar_url'] . '" />',
'href' => '',
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']) && !empty($modSettings['default_avatar_url']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $modSettings['default_avatar_url'] . '" />',
'href' => $modSettings['default_avatar_url'],
'url' => '',
);

elseif(empty($context['user']['avatar']['image']) && !empty($modSettings['enable_default_avatar']))
$context['user']['avatar'] = array(
'name' => '',
'image' => '<img class="avatar" src="' . $settings['images_url'] . '/default_avatar.png" />',
'href' => '',
'url' => '',
);
// Default avatar mod ends.



Sources/ManageSettings.php
Code (Find and remove) Select
array('check', 'enable_default_avatar'),
array('text', 'default_male_avatar_url'),
array('text', 'default_female_avatar_url'),
array('text', 'default_avatar_url', 50, 'subtext' => $txt['default_avatar_path']),



Ohh and I placed the code in your post in [ code ] [ /code] tags.

thanks joker i managed to do this  ;D
Title: Re: Default Avatar
Post by: Joker™ on October 23, 2011, 01:29:57 PM
Quote from: T3CHN0 on October 23, 2011, 09:51:26 AM
thankyou for such a great mod, works better then the other 2 default/generic avatar mods.
only problem is FireFox 7 doesn't recognize download names with spaces and your mod will download as
""default"" and not ""Default Avatar For SMF 2X.zip"" if you could rename your download file to Default_Avatar_For_SMF_2X.zip
it will stop others asking later on why there is no file extension on the download.
Maybe FireFox will fix there bug maybe not but to save everyones time. best to rename the download I think.

Cheers
yeah, I'll try my best to find some time by tomorrow to rename all of my mods around here :).
Title: Re: Default Avatar
Post by: pixeleyes on November 08, 2011, 09:34:18 AM
During installation I got an error

3.    Execute Modification    ./Sources/ManageSettings.php    Test failed
1.    Add After    ./Sources/ManageSettings.php                            Test failed

So I tried to add manually code in ManageSettings.php but could not find below code in file.

Find
$config_vars = array(
// Mod authors, add any settings UNDER this line. Include a comma at the end of the line and don't remove this statement!!


So don't know where should I add below one.
Add after array('check', 'enable_default_avatar'),
array('text', 'default_male_avatar_url'),
array('text', 'default_female_avatar_url'),
array('text', 'default_avatar_url', 'subtext' => $txt['default_avatar_path']),
array('check', 'default_avatar_opacity'),

Title: Re: Default Avatar
Post by: Joker™ on November 08, 2011, 03:31:25 PM
Sources/ManageSettings.php

Attach the file over here.
Title: Re: Default Avatar
Post by: Wiejeben on December 19, 2011, 05:08:41 AM
Does anyone know if http://www.somesite.com/avatars/$contect['user']/ is possible? (I'm using a service that grabs someones Minecraft avatar by URL.
Title: Re: Default Avatar
Post by: T3CHN0 on December 19, 2011, 05:46:26 AM
Quote from: Wiejeben on December 19, 2011, 05:08:41 AM
Does anyone know if http://www.somesite.com/avatars/ (http://www.somesite.com/avatars/)$contect['user']/ is possible? (I'm using a service that grabs someones Minecraft avatar by URL.
I wouldn't think so
To my understanding the link you posted is cross linking
the first part beinghttp://www.somesite.com/avatars/ (http://www.somesite.com/avatars/) next part being $contact['user'] is making it look back onto your site
for example if your site was called http://www.mysit.com (http://www.mysit.com) then your browser thinks your looking for
http://www.somesite.com/avatars (http://www.somesite.com/avatars)/http://www.sysite.com/avatar (http://www.sysite.com/avatar) to collect the avatar that a user has already selected.

I don't know for sure.... but this is how I would understand it.

I don't know how' you would redirect your site to look at another site for avatars.
I personally don't think it's a good idea thou... it will drag your site making it slower because
the avatars it needs to display are else where. and if say that other site stops leaches! you will no longer
see avatars and will need to fix it back to defaults again.

You would be better off downloading all the avatars and adding them to your site.
would be faster for your members and less forum lag.
Title: Re: Default Avatar
Post by: Joker™ on December 19, 2011, 06:06:49 AM
Quote from: T3CHN0 on December 19, 2011, 05:46:26 AM
I personally don't think it's a good idea thou... it will drag your site making it slower because
the avatars it needs to display are else where. and if say that other site stops leaches! you will no longer
see avatars and will need to fix it back to defaults again.

You would be better off downloading all the avatars and adding them to your site.
would be faster for your members and less forum lag.

Exact to the point reply. Thanks T3CHN0 ;).
Title: Re: Default Avatar
Post by: Eclipse16V on December 29, 2011, 12:57:25 AM
Thanks for this Mod.
Title: Re: Default Avatar
Post by: Seath on October 20, 2012, 09:24:35 AM
Hello,

I have smf 2.0.2 and I installed the Default Avatar mod, but the avatar doesn't shows up. I really don't know what else to say, because I have no idea what's wrong. I have no php errors or any error of any kind.

Thanks.
Title: Re: Default Avatar
Post by: Shambles on October 20, 2012, 09:36:40 AM
@ Seath

Did you set the option(s) especially the first?

Admin > Configuration > Modification Settings > Miscellaneous

Enable Default Avatar
Image path for Default Avatar image for male members
Image path for Default Avatar image for female members
Image path for Default Avatar image
Title: Re: Default Avatar
Post by: Seath on October 20, 2012, 09:45:12 AM
Well that's just embarrassing  :-X I guess I missed that part. I'm sorry  O:)
Its working now.
Thanks Shambles
Title: Re: Default Avatar
Post by: FragaCampos on June 20, 2013, 12:27:37 PM
Thank you, it's a simple yet useful mod.

Working without errors on a heavy moded 2.0.4 forum.
Title: Re: Default Avatar
Post by: Rain Forest on July 10, 2013, 02:17:46 PM
Thank for the mod! Works on SMF 2.0.4 :)

However: how can I make this compatible with the Buddy page mod: http://custom.simplemachines.org/mods/index.php?mod=2204

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fs20.postimg.org%2Fzcd3ea00d%2FUntitled_2.jpg&hash=b3851cd9beef5bb5bbeb9e7fc270faa3663b8961)
Title: Re: Default Avatar
Post by: Joker™ on July 14, 2013, 10:35:36 AM
Quote from: Soft Drink on July 10, 2013, 02:17:46 PM
Thank for the mod! Works on SMF 2.0.4 :)

However: how can I make this compatible with the Buddy page mod: http://custom.simplemachines.org/mods/index.php?mod=2204

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fs20.postimg.org%2Fzcd3ea00d%2FUntitled_2.jpg&hash=b3851cd9beef5bb5bbeb9e7fc270faa3663b8961)
Well it's not that hard to integrate mods with each other, but as the 'Buddy Page' doesn't not have any license associated to it, so I can't tweak it officially. I'll try to get in touch with Runic (http://www.simplemachines.org/community/index.php?action=profile;u=23577) and see if we both can come up with some solution :).
Title: Re: Default Avatar
Post by: Rain Forest on July 14, 2013, 06:34:17 PM
I'll wait for guys :)

Thanks, Joker :)
Title: Re: Default Avatar
Post by: Dzonny on July 17, 2013, 06:52:05 PM
If I may suggest, "image path" in mods settings should be change to "Image url" as I tried for 20 minutes to type different paths to images in order to get it working with just url. :s
Title: Re: Default Avatar
Post by: Joker™ on July 21, 2013, 11:39:49 PM
Quote from: Dzonny on July 17, 2013, 06:52:05 PM
If I may suggest, "image path" in mods settings should be change to "Image url" as I tried for 20 minutes to type different paths to images in order to get it working with just url. :s
Lol, yup seems to be a legit text change.
Title: Re: Default Avatar
Post by: Joker™ on July 28, 2013, 09:26:53 AM
Mod updated with
- Extended support for other mods
- License change
- Github repo
- Bug fixes
Title: Re: Default Avatar
Post by: wumpyc on July 30, 2013, 03:37:40 AM
When I install it my letters become bigger and I get some text at the top of my page
Here's a screenshot:
puu.sh/3PeGi.jpg
Title: Re: Default Avatar
Post by: Joker™ on July 30, 2013, 01:36:08 PM
Quote from: wumpyc on July 30, 2013, 03:37:40 AM
When I install it my letters become bigger and I get some text at the top of my page
Here's a screenshot:
puu.sh/3PeGi.jpg
Well it seems like there is some issue with Modification.english.php. Please attach the file over here:

Themes/default/languages/Modifications.english.php
Title: Re: Default Avatar
Post by: Draffi on July 31, 2013, 07:30:53 PM
@Joker:

Can i ask what exactly this means?

- Extended support for other mods

(What mods are supported?)
Title: Re: Default Avatar
Post by: TheListener on July 31, 2013, 07:39:38 PM
Quote from: Draffi on July 31, 2013, 07:30:53 PM
@Joker:

Can i ask what exactly this means?

- Extended support for other mods

(What mods are supported?)

Mods which are avatar related I expect.
Title: Re: Default Avatar
Post by: wumpyc on August 01, 2013, 09:54:36 AM
Quote from: Joker™ on July 30, 2013, 01:36:08 PM
Quote from: wumpyc on July 30, 2013, 03:37:40 AM
When I install it my letters become bigger and I get some text at the top of my page
Here's a screenshot:
puu.sh/3PeGi.jpg
Well it seems like there is some issue with Modification.english.php. Please attach the file over here:

Themes/default/languages/Modifications.english.php
here
Title: Re: Default Avatar
Post by: Joker™ on August 01, 2013, 09:55:39 AM
Quote from: Old Fossil on July 31, 2013, 07:39:38 PM
Quote from: Draffi on July 31, 2013, 07:30:53 PM
@Joker:

Can i ask what exactly this means?

- Extended support for other mods

(What mods are supported?)

Mods which are avatar related I expect.
Thanks a lot oldies :P. Really without you I'd have to give a lot of mod support answers, really.

Draffi, like there is a mod called Buddy Page (http://custom.simplemachines.org/mods/index.php?mod=2204) which shows user buddy's info. Such mods were unable to show avatar for members which weren't having any avatar.

With new extended capabilities such mods can integrate this mod and show default avatars.

I hope this helps :).
Title: Re: Default Avatar
Post by: Joker™ on August 01, 2013, 10:00:01 AM
Quote from: wumpyc on August 01, 2013, 09:54:36 AM
Quote from: Joker™ on July 30, 2013, 01:36:08 PM
Quote from: wumpyc on July 30, 2013, 03:37:40 AM
When I install it my letters become bigger and I get some text at the top of my page
Here's a screenshot:
puu.sh/3PeGi.jpg
Well it seems like there is some issue with Modification.english.php. Please attach the file over here:

Themes/default/languages/Modifications.english.php
here
Hi wumpyc,

Your modifications.english.php doesn't look fine, as its not having any of the mod related text strings.

Please check whether the mod is installed properly or not. You can use this link (http://custom.simplemachines.org/mods/index.php?action=parse;mod=2665;attach=222698;smf_version=2.0.4) and check each file manually which is being tweaked by the mod at the time of installation.
Title: Re: Default Avatar
Post by: wumpyc on August 03, 2013, 01:37:53 AM
Quote from: Joker™ on August 01, 2013, 10:00:01 AM
Quote from: wumpyc on August 01, 2013, 09:54:36 AM
Quote from: Joker™ on July 30, 2013, 01:36:08 PM
Quote from: wumpyc on July 30, 2013, 03:37:40 AM
When I install it my letters become bigger and I get some text at the top of my page
Here's a screenshot:
puu.sh/3PeGi.jpg
Well it seems like there is some issue with Modification.english.php. Please attach the file over here:

Themes/default/languages/Modifications.english.php
here
Hi wumpyc,

Your modifications.english.php doesn't look fine, as its not having any of the mod related text strings.

Please check whether the mod is installed properly or not. You can use this link (http://custom.simplemachines.org/mods/index.php?action=parse;mod=2665;attach=222698;smf_version=2.0.4) and check each file manually which is being tweaked by the mod at the time of installation.
The mod is currently not installed. I have uninstalled it because of that issue. Do you want me to pop you up Modification.english.php with Default Avatar installed?
Title: Re: Default Avatar
Post by: Joker™ on August 03, 2013, 10:59:02 AM
Quote from: wumpyc on August 03, 2013, 01:37:53 AM
The mod is currently not installed. I have uninstalled it because of that issue. Do you want me to pop you up Modification.english.php with Default Avatar installed?
Umm clarify me with few questions:

1. Issues happens with mod installed?
2. Is your website fine after uninstalling the mod?
3. Any errors while installing the mod?
4. Any errors while uninstalling the mod?
5. Are you installing the mod via package manager or manually?
6. Which version of SMF are you using?

- Joker™
Title: Re: Default Avatar
Post by: BeerHuntor on September 05, 2013, 10:01:56 PM
Having issues with this mod,  currently running version 2.0.2 installed flawlessly, made my member groups as invisible, and forced users to use the avatar, but when i type the avatar url into the "image path" the image doesnt show up, just shows like a box with an x in the middle indicating it cant show the image can someone please help me
Title: Re: Default Avatar
Post by: Burke ♞ Knight on September 05, 2013, 10:21:31 PM
How exactly are you entering in the URL to the image?
Title: Re: Default Avatar
Post by: BeerHuntor on September 05, 2013, 10:23:43 PM
h t t p s://www.army.mod.uk/images/general-content/finalrank_blank.gif

(without the spaces obviously, cant post links under 10 posts)
Title: Re: Default Avatar
Post by: Burke ♞ Knight on September 05, 2013, 10:28:14 PM
Try to put the image in the Avatars folder.
Then link to it there. That may or may not help, but it's an idea. :)
Title: Re: Default Avatar
Post by: Tennant on August 04, 2014, 11:37:22 PM
Error I get whenever I try to make a new member group.

Mod installed:

http://custom.simplemachines.org/mods/index.php?mod=2665

Error log:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi.imgur.com%2F2kwGZEs.png&hash=4d664a81e9ac075d8963ae09f25af08f5259f864)
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi.imgur.com%2FoxCthxC.png&hash=214ae7922fb812a4128ef4ebb38e2e242378a243)

Any help?
Title: Re: Default Avatar
Post by: Joker™ on August 10, 2014, 02:37:55 AM
Quote from: Tennant on August 04, 2014, 11:37:22 PM
Error I get whenever I try to make a new member group.
Hey,

This mod doesn't make such edit. It looks like the error is coming up due to some other mod.
Title: Re: Default Avatar
Post by: richardwbb on January 12, 2017, 07:48:45 PM
I am aware that the author isn't really available, though I'm not seeking support. I noticed that this topic hasn't been posted to for atleast one hundred twenty days, but;

When I did a file search on my computer, coincidentally, found a 'default avatar', it is from a theme 'Adwaita', released under GNU GPL 2.

Because this modification was something I was looking for and because I believe this avatar is modern and real slick, I decided to share it for you to grab. It is in a large format so you might want to resize to a hundred by a hundred.

http://parkeerdoos.netau.net/map/simplemachines/avatar-default.png (http://parkeerdoos.netau.net/map/simplemachines/avatar-default.png)
Title: Re: Default Avatar
Post by: jcarnes on June 20, 2018, 06:22:23 PM
I'm pretty new to dealing with mods. I'm trying to figure out where to put the default avatars for male and female since I want to host the files myself and not pull them in from the Internet. I'm using 3 themes and would like the avatars to show up on all of them. Any ideas or guidance would be great. Thanks for an excellent mod!
Title: Re: Default Avatar
Post by: vbgamer45 on June 20, 2018, 06:23:52 PM
Right now the main file is stored in
Theme><YourTheme>/images/default_avatar.png
Title: Re: Default Avatar
Post by: richardwbb on June 20, 2018, 06:35:43 PM
I'm not sure what you are referring to jcarnes, vbgamer45, but I am aware my previous link is down.

This is a permanent link http://www.fotobakje.nl/map/div/smf/avatar-default.png (http://www.fotobakje.nl/map/div/smf/avatar-default.png)

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.fotobakje.nl%2Fmap%2Fdiv%2Fsmf%2Favatar-default.png&hash=54679da151836722e2e078fd1ae95b5583a31e19)

It's not female but it's creative commons licensed. I'm aware the image doesn't come with a license. It's a default Linux Debian image/ icon.
Title: Re: Default Avatar
Post by: jcarnes on June 20, 2018, 06:37:56 PM
Quote from: vbgamer45 on June 20, 2018, 06:23:52 PM
Right now the main file is stored in
Theme><YourTheme>/images/default_avatar.png

That did it! Thanks for the quick reply too!!   :)
Title: Re: Default Avatar
Post by: vbgamer45 on June 20, 2018, 09:45:56 PM
Glad to help
Title: Re: Default Avatar
Post by: Mick. on July 28, 2018, 08:37:02 PM
Perfect brother..i was looking for that avatar mod that enforces new registers to add an avatar upon sign up but this is cooler option. Thanx man!
Title: Re: Default Avatar
Post by: shadav on August 29, 2019, 08:38:58 PM
yes I know it's old, sorry :)
anyone can help me maybe?
2.0.15 I'd like to show the default avatars on the board index/child board index as well, instead of the little grey default that comes with smf
Title: Re: Default Avatar
Post by: vbgamer45 on August 29, 2019, 09:03:32 PM
Different mod you would use https://custom.simplemachines.org/mods/index.php?mod=4107
Title: Re: Default Avatar
Post by: shadav on August 30, 2019, 08:39:13 AM
Quote from: vbgamer45 on August 29, 2019, 09:03:32 PM
Different mod you would use https://custom.simplemachines.org/mods/index.php?mod=4107
thank you... I think I have that one, but how can I get it to work with this mod? to display the default avatars instead of the "blank" avatar
Title: Re: Default Avatar
Post by: vbgamer45 on August 30, 2019, 08:45:08 AM
That would be a question for the other mod. They would have to add support for it.
Title: Re: Default Avatar
Post by: shadav on August 30, 2019, 08:49:25 AM
Quote from: vbgamer45 on August 30, 2019, 08:45:08 AM
That would be a question for the other mod. They would have to add support for it.
ok, thank you :)