[2.0.19] Default avatar

All new MODs released in our MOD Database will be announced in here. All support for released MODs needs to take place in here. No new MODs will be accepted into the MOD Database for phpBB2
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.

Rating:

Excellent!
29
58%
Very Good
6
12%
Good
8
16%
Fair
1
2%
Poor
6
12%
 
Total votes: 50

TStarGermany
Registered User
Posts: 16
Joined: Fri Nov 11, 2005 7:58 pm
Contact:

Post by TStarGermany » Sun Feb 26, 2006 7:09 pm

i hope you don't mind if i post that here:

i was looking for this mod, but read about the advice not to install it... but actually i wanted it,so i made a very small (and working hack).. may help you until the next release of the mod comes out...

here we go:
1) make a nice defaultavatar.gif (=standard), put it in your forum/images/avatars/ directory (where all the uploaded avatars reside).

2) open includes/usercp_avatar.php
at the beginning of the user_avatar_delete function you'll find:

Code: Select all

if ( $avatar_type == USER_AVATAR_UPLOAD && $avatar_file != '' ) 
replace it with

Code: Select all

if ( $avatar_type == USER_AVATAR_UPLOAD && $avatar_file != '' && $avatar_file !='defaultavatar.gif')
at the end of the user_avatar_delete function you'll find:

Code: Select all

return ", user_avatar = '', user_avatar_type = " . USER_AVATAR_NONE;
replace it with

Code: Select all

return ", user_avatar = 'defaultavatar.gif', user_avatar_type = " . USER_AVATAR_UPLOAD;
save+close.

3) open includes/usercp_register.php
find

Code: Select all

$sql = "INSERT INTO " . USERS_TABLE . "	(user_id, username, user_regdate, user_password, user_e............
before,add

Code: Select all

$avatar_sql = "'defaultavatar.gif', '1'";
that should be about it...

what it does:
when a user signs up, defaultavatar.gif (as user_avatar) and '1' (as user_avatar_type) are inserted into the database...
later,when a user changes his avatars,everything remains the same as ever,
except: when a user decides to explicetely delete his avatar, the new values for user_avatar & user_avatar_type (written to the database after deleting the physical picture file) are not '' and '' anymore, but the values for the default avatar... (of course the avatar picture is only phyiscally deleted if it's not the defaultavatar.gif)

it has no admin GUI,does not insert the defaultavatar for old users, who have no avatar (which would actually be a very short addon script)... but it works...

tell me if i'm lame ^^
Last edited by TStarGermany on Sun Feb 26, 2006 10:40 pm, edited 1 time in total.

User avatar
Liljeberg
Registered User
Posts: 34
Joined: Tue Jan 10, 2006 8:09 am

Post by Liljeberg » Sun Feb 26, 2006 8:24 pm

Can someone quickly explain to me what the problem is that people is having? This mod seems to work perfectly on my board.

Parm
Registered User
Posts: 34
Joined: Sat Oct 08, 2005 6:34 pm

Post by Parm » Sat Mar 11, 2006 6:34 pm

Manipe wrote: Yes I would advise you to wait, although my initial projection of a few days may be a little bit off because of the server being moved, and because of the size of the queue.

Manipe, any ideas on how long this one might be?

Manipe
Former Team Member
Posts: 1146
Joined: Thu Jul 22, 2004 6:30 pm
Location: Éire
Contact:

Post by Manipe » Sat Mar 11, 2006 11:23 pm

Well, the queue is quite big at the moment so I'm sorry to say it will be another small while. How long I don't know, but hopefully not too long.

the wait will be worth it.
My MODs: [ Topics a user has started ] , [ Profile views ] , [ Colour on poll results ] , [ Topic posters ] , [ Add number to PM ] , [ Default avatar ] , [ View category name ] , [ Null vote ] , [ Forum description in viewforum ] , [ Resync forum ids ] , [ View PM while replying ] , [ Quick poll insert ] , [ Limit login attempts ] , [ Track PMs ]

www.ManipeF1.com

Manipe
Former Team Member
Posts: 1146
Joined: Thu Jul 22, 2004 6:30 pm
Location: Éire
Contact:

Post by Manipe » Sat Mar 11, 2006 11:23 pm

Well, the queue is quite big at the moment so I'm sorry to say it will be another small while. How long I don't know, but hopefully not too long.

the wait will be worth it.
My MODs: [ Topics a user has started ] , [ Profile views ] , [ Colour on poll results ] , [ Topic posters ] , [ Add number to PM ] , [ Default avatar ] , [ View category name ] , [ Null vote ] , [ Forum description in viewforum ] , [ Resync forum ids ] , [ View PM while replying ] , [ Quick poll insert ] , [ Limit login attempts ] , [ Track PMs ]

www.ManipeF1.com

User avatar
webmacster87
Former Team Member
Posts: 3758
Joined: Fri Jun 11, 2004 2:30 am
Location: San Mateo, CA
Name: Douglas Bell
Contact:

Post by webmacster87 » Sun Mar 12, 2006 3:39 pm

MOD Updated to version 2.0.0b
See first post for Download Link

Manipe
Former Team Member
Posts: 1146
Joined: Thu Jul 22, 2004 6:30 pm
Location: Éire
Contact:

Post by Manipe » Sun Mar 12, 2006 4:02 pm

Low and behold, the new generation Default Avatar.
The code has been totally reworked, with many new features, including random default avatar. All the options can be found under all the current avatar options.

Hopefully this will not have as many bugs as the previous version :D
My MODs: [ Topics a user has started ] , [ Profile views ] , [ Colour on poll results ] , [ Topic posters ] , [ Add number to PM ] , [ Default avatar ] , [ View category name ] , [ Null vote ] , [ Forum description in viewforum ] , [ Resync forum ids ] , [ View PM while replying ] , [ Quick poll insert ] , [ Limit login attempts ] , [ Track PMs ]

www.ManipeF1.com

User avatar
Yasamin
Registered User
Posts: 73
Joined: Fri Dec 09, 2005 5:06 am
Location: Earth

Post by Yasamin » Sun Mar 12, 2006 4:06 pm

Is there an option to tie avatar to rank? (for those who haven't chosen their own avatar)

Parm
Registered User
Posts: 34
Joined: Sat Oct 08, 2005 6:34 pm

Post by Parm » Mon Mar 13, 2006 5:26 pm

Manipe wrote: Low and behold, the new generation Default Avatar.
The code has been totally reworked, with many new features, including random default avatar. All the options can be found under all the current avatar options.

Hopefully this will not have as many bugs as the previous version :D

Thanks Manipe!
Am now using the new version @ www.divasgaming.com/forums
Installation was simple, and the mod works perfectly! :D

If I was to be very picky, I would say that when you set it to choose a random avatar from the gallery. The avatar chosen for those users change each time you refresh. It'd be handy if it were to pick out an avatar by random and assign it to that user for him/her to keep until they change it.

fahraeus
Registered User
Posts: 134
Joined: Tue Nov 23, 2004 3:47 pm

Post by fahraeus » Mon Mar 13, 2006 11:17 pm

I've been waiting for this moment ;)
IMHO the perfect random default avatar would work something like this:

1. User 1 registers and gets an random avatar for all posts automatically
2. Next user registers and gets a different avatar automatically.
3. And so on...

Alas, the point would be to assure that every user of the board have an avatar - so it would be easier to follow the discussions of the board.

Would there be a possibility to somehow incorporate this into the mod - or would this be something you find worth coding as a different mod?

fahraeus wrote:
Manipe wrote:If you like I could give you an add-on for it when it is released.


Awesome. That's really nice of you. I have been looking for a mod like this for ages.

Thank you very very much in advance.

Manipe
Former Team Member
Posts: 1146
Joined: Thu Jul 22, 2004 6:30 pm
Location: Éire
Contact:

Post by Manipe » Tue Mar 14, 2006 9:47 pm

I understand that that's what you'd like done, but at the moment, i'm totally swamped with work, so it's not going to be possible for a while.
I'll get around to it when I can, but I don't know when. Sorry.
My MODs: [ Topics a user has started ] , [ Profile views ] , [ Colour on poll results ] , [ Topic posters ] , [ Add number to PM ] , [ Default avatar ] , [ View category name ] , [ Null vote ] , [ Forum description in viewforum ] , [ Resync forum ids ] , [ View PM while replying ] , [ Quick poll insert ] , [ Limit login attempts ] , [ Track PMs ]

www.ManipeF1.com

User avatar
Yasamin
Registered User
Posts: 73
Joined: Fri Dec 09, 2005 5:06 am
Location: Earth

Post by Yasamin » Wed Mar 15, 2006 12:04 am

Manipe wrote: I understand that that's what you'd like done, but at the moment, i'm totally swamped with work, so it's not going to be possible for a while.
I'll get around to it when I can, but I don't know when. Sorry.


We'll gladly wait patiently and politely 'cause it's such a cool suggestion for such a cool MOD :D



We'll also wait for this feature, patiently and politely:
I wrote: Is there an option to tie avatar to rank? (for those who haven't chosen their own avatar)


I went ahead and installed to MOD to see if that was a feature, but it's not (yet) ;)

MickeyJim
Registered User
Posts: 13
Joined: Thu Sep 15, 2005 3:21 pm
Location: Bristol, UK
Contact:

Post by MickeyJim » Mon Apr 10, 2006 3:26 pm

I just installed this mod and it works a treat ;)
Nice one, didn't relise how recent this mod was until I read through the topic.

I did like the random avatar feature but what I would like is the ability to manage the randomness for Guests and Members seperately,
Example: have Members set to random but guests set to a fixed avatar so Guests avatars always say "guest" on them but members ones are random
Or both both set to random but different directories so that if you had a directory of blue avatars for members and green for guests.
Mike
University Student, Bristol
Forums Managed: Scout & Guide, Film & Movie, Go Jamboree! - WSJ 2007

joeydee
Registered User
Posts: 292
Joined: Tue Mar 07, 2006 2:05 am

Post by joeydee » Fri Apr 21, 2006 12:06 am

HI,

I instaled everything, i log into my admin, and the left hand site in the frame it says, ERROR on LINE 265 "Admin_Users.php"

So i open the PHP file, look aton line 265 and its

Code: Select all

// Default avatar MOD, By Manipe (Begin) 
$allowdefaultavatar = ( isset( $HTTP_POST_VARS['allowdefaultavatar']) ) ? ( ( $HTTP_POST_VARS['allowdefaultavatar'] ) ? TRUE : 0 ) : 0;
// Default avatar MOD, By Manipe (End)
SO this is line 265:

$allowdefaultavatar = ( isset( $HTTP_POST_VARS['allowdefaultavatar']) ) ? ( ( $HTTP_POST_VARS['allowdefaultavatar'] ) ? TRUE : 0 ) : 0;

I have no idea whats wrong... I spend around 2 hours looking at the same file and i couldn't find anything, can somone please give me hand.
Regards,
Joey

joeydee
Registered User
Posts: 292
Joined: Tue Mar 07, 2006 2:05 am

Post by joeydee » Fri Apr 21, 2006 1:14 am

I forgot to mention the ERROR for VIEWTOPIC.php

Code: Select all

Could not obtain post/user information.

DEBUG MODE

SQL Error : 1064 You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '.*, pt.post_text, pt.post_subject, pt.bbcode_uid FROM phpbb_p

SELECT u.username, u.user_id, u.user_posts, u.user_from, u.user_website, u.user_email, u.user_icq, u.user_aim, u.user_yim, u.user_regdate, u.user_msnm, u.user_viewemail, u.user_rank, u.user_sig, u.user_sig_bbcode_uid, u.user_avatar, u.user_avatar_type, u.user_allowavatar, u.user_allowsmile,u.user_allowdefaultavatar p.*, pt.post_text, pt.post_subject, pt.bbcode_uid FROM phpbb_posts p, phpbb_users u, phpbb_posts_text pt WHERE p.topic_id = 3 AND pt.post_id = p.post_id AND u.user_id = p.poster_id ORDER BY p.post_time ASC LIMIT 0, 15

Line : 400
File : viewtopic.php
Can you please help me out.
JOey

Post Reply

Return to “[2.0.x] MOD Database Releases”