There was always an error message displaying at the top right corner of the private message windows, saying "Image load error" in red.
I guess i finally fixed it by commenting out these lines in vbulletin36CMS.php:
PHP Code:
//$this->getAvatar = new Statement("SELECT * FROM {$prefix}customavatar WHERE userid = ? AND visible = 1");
//$this->getPicture = new Statement("SELECT * FROM {$prefix}customprofilepic WHERE userid = ? AND visible = 1");
PHP Code:
// Get current profile picture or avatar
// This function is only supported if you use the database storage method in vbulletin
// function getPhoto($userid)
//{
//if($_SESSION['fc_users_cache'][$userid]['pid'] == $userid)
//{
//return $_SESSION['fc_users_cache'][$userid]['fpath'];
//}
//if($GLOBALS['vbulletin']['useavatar'])
//{
// $rs = $this->getAvatar->process($userid);
//}
//else
//{
// $rs = $this->getPicture->process($userid);
//}
//if(($rec = $rs->next()) == null) return '';
//$fparts = explode('.', $rec['filename']);
//$fname = strtolower('$'.substr('000000'.$userid,-6).'$'.$rec['dateline'].'.'.$fparts[count($fparts)-1]);
//$fpath = './images/cust_img/'.$fname;
//if(!file_exists($fpath))
//{
// $fp = fopen($fpath, 'wb');
// fwrite($fp, $rec['filedata']);
// fflush($fp);
// fclose($fp);
//}
//$_SESSION['fc_users_cache'][$userid]['pid'] = $userid;
//$_SESSION['fc_users_cache'][$userid]['fpath'] = $fpath;
//return $fpath;
//}
PHP Code:
//'useavatar' => true, // True = use custom avatar for flashchat photo feature, False = use custom profile picture.
It says:
Quote:
This function is only supported if you use the database storage method in vbulletin
|
I use filesystem.
PHP Code:
'useavatar' => true, // True = use custom avatar for flashchat photo feature, False = use custom profile picture.
There must be an option to completely disable both avatars and profile pictures.
Another question...
I've seen this part in your integration mod:
PHP Code:
// Get male or female
function getGender($user)
{
return NULL;
}
I've gender customfields defined at my vb. How can i use it for the code above?
Thanks