Version: , by Kier
Developer Last Online: May 2011
Version: 2.2.x
Rating:
Released: 03-18-2001
Last Update: Never
Installs: 52
No support by the author.
Updated for vBulletin 2.2.2, 5th February 2002
Since there has been so much demand for this, I wrote a hack that will allow you to store all your custom avatars as files, rather than in the mySQL database.
Doing this will have the following benefits:
Avatars folder can be protected by .htaccess (Apache only) to prevent bandwidth stealing
No SQL queries or PHP code required to display custom avatars - server load decreases
No cacheing issues with Internet Explorer 5.5, so server bandwidth use should decrease
The install script will make the necessary modifications to your database, install a control panel option to switch the file-based avatars on, and convert your existing custom avatars from the database into files.
All avatar options that are present when using the standard mySQL avatar system are still present, and users will not notice a difference in the interface.
Full instructions for altering your PHP files are included in the zip file.
Once you have made the necessary modifications to the PHP scripts, you should run the enclosed install_favatar.php script from your admin/ folder.
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
Has anyone been able to make this work on VB 2.0.1? What changes in the instructions did you do? I "really" like to incorporate this hack coz it'll save me valuable database space, as well as protect my avatar images with mod_rewrite ...
Originally posted by Tolitz Has anyone been able to make this work on VB 2.0.1? What changes in the instructions did you do? I "really" like to incorporate this hack coz it'll save me valuable database space, as well as protect my avatar images with mod_rewrite ...
See this,I edit this hack from Kier.
It works well on my board vb2.0.1.
this zip include two files. install_db2fileavatars.php adn install.txt.
Unzip this zip,upload and run install_db2fileavatars.php in your board admin dir.Then edit and upload your file as install.txt.
Good luck!
Only problem with ztsky's version of this hack is that the avatar will no longer display on the profile page, whether it's your edit profile page or someone else's view profile page. Can you modify the 'hack' in the members.php file so it still shows it in profile pages? Works fine otherwise.
Originally posted by Dimitri Only problem with ztsky's version of this hack is that the avatar will no longer display on the profile page, whether it's your edit profile page or someone else's view profile page. Can you modify the 'hack' in the members.php file so it still shows it in profile pages? Works fine otherwise.
just like this
in member.php,
1??find :
Code:
$userinfo[avatarurl]=getavatarurl($userinfo[userid]);
if ($userinfo[avatarurl]=="") {
$userinfo[avatarurl]="images/clear.gif";
replace with this:
Code:
$userinfo[avatarurl]=getavatarurl($userinfo[userid]);
if ($userinfo[avatarurl]=="") {
if ($userinfo[avatarrevision]>0) {
$userinfo[avatarurl]="custom_avatars/avatar$userinfo[userid]"."_$userinfo[avatarrevision].gif";
} else
$userinfo[avatarurl]="images/clear.gif";
2??find
Code:
if ($bbuserinfo[avatarurl]=="") {
$bbuserinfo[avatarurl]="images/clear.gif";
replace with this:
Code:
if ($bbuserinfo[avatarurl]=="") {
if ($bbuserinfo[avatarrevision]>0) {
$bbuserinfo[avatarurl]="custom_avatars/avatar$bbuserinfo[userid]"."_$bbuserinfo[avatarrevision].gif";
} else
$bbuserinfo[avatarurl]="images/clear.gif";
Originally posted by Dakota
the dateline you guys are talking about didn't affect it when I installed it. I just acted like it wasn't there, and just put what is in the installation instructions. It works fine without the dateline stuff.
I've got 2.0.0. So do I just ignore the dateline stuff and put what's in the installation instruction? Will it really work?
I'm hesitant of hacking the code unless I'm 100% sure it will work and not crash.
btw can somebody update the instruction for 2.0.x users?