Mod Name / Version: Upload Avatar 1.0.3 <br /> <br />Description: Allows an administrator to upload a user's avatar. <br /> <br />Working Under: UBB.Threads 6.2-6.3 <br /> <br />Mod Status: Finished <br /> <br />Any pre-requisites: PHP >= 4.0.5 <br /> <br />Author(s): Dave_L <br /> <br />Date: 05/30/03 <br /> <br />Credits: <br /> <br />Files Altered: admin/menu.php (optional) <br /> <br />New Files: admin/upload_avatar.php <br /> <br />Database Altered: yes (updates Users.U_Picture, Users.U_PicWidth and Users.U_PicHeight) <br /> <br />Info/Instructions: This addon script allows an administrator to upload an avatar for a user, regardless of whether users are permitted to upload their own avatars. The database is updated appropriately. <br /> <br />The avatar directory path, URL and the maximum avatar file size are obtained from the config settings $config['avatars'], $config['avatarurl'] and $config['avatarsize']. <br /> <br />The maximum avatar dimensions are obtained from the theme settings $theme['PictureWidth'] and $theme['PictureHeight']. <br /> <br />The permissible avatar file types (.gif, .jpg and .png) are hardcoded here. <br /> <br />The PHP function getimagesize is used for checking the image dimensions and image type. <br /> <br />------------ <br />The instructions show how to add this function to the admin menu, but you can also run this as a standalone script, if you prefer not to modify admin/menu.php. <br />------------ <br /> <br />HISTORY: <br /> 2003-03-01 Dave_L - 1.0.0 Original release <br /> 2003-04-21 Dave_L - 1.0.1 Updated instructions for UBB.threads 6.3b1 <br /> 2003-05-12 Dave_L - 1.0.2 chmod uploaded file to 0666 <br /> 2003-05-30 Dave_L - 1.0.3 Record actions in admin log <br /> <br /> <br />Disclaimer: Please backup every file that you intend to modify. <br />If the modification modifies the database, it's a good idea to backup your database before doing so. <br /> <br />Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you'll need to restore unmodified files.
Attachments
79896-upload_avatar_1-0-3.zip (59 downloads)
Edited by Dave_L (05/30/03 02:24 AM)
_________________________
UBB.threads beta tester / threadsdev.com moderator
Software consulting services including UBB.threads problem resolution / installs / upgrades / customization.