MOD Description: Enables the user_posts field to determine whether or not avatars should be enabled for a user.
MOD Version: 1.0.7 (01/24/2007)
MOD Download: http://test.medinaline.net/Enable_Avata ... _1.0.7.mod
Demo Board: http://test.medinaline.net
Made minor changes to the code as requested by the mod validation team. The issues with the ACP have been fixed, also templates code rewritten to allow for greater compatibility with more skins. Resubmitted for mod validation.
For the demo, join the test board with bogus information. Check the profile, avatars are disabled by default. Make two test posts, view your posts. It's that simple, folks. You can log in as admin to see the new ACP (login as James / James, go to ACP, general administration)
After installing this mod, you would need to run the following SQL statement once to get the users table up to date:
Code: Select all
UPDATE phpbb_users SET user_allowavatar = 1 WHERE user_posts >= XXX
If you don't want to "grandfather" users in (meaning, if they are allowed to have avatars now, but after the mod you don't want them to) run the following SQL statement once:
Code: Select all
UPDATE phpbb_users SET user_allowavatar = 0 WHERE user_posts < XXX
This mod won't do anything for you if you don't disable avatars by default for new users.
Now, the thought process behind using the "viewtopic.php" page to do this function, is that all the information you need to check is already being pulled there... And, unless modded away, by default phpBB redirects you back to view your post after making a new post... So... Right then, the database is updated with your new avatar permissions.
The mod is simple enough, that it could easily be modified to update other fields of information in the users table (allowing other permission related things, like smilies, bbcode, etc.)