The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#11
|
|||
|
|||
Alright, I looked at showgroups.php once more and tried to figure out what the vital parts of the query would be. I came up with this:
Code:
$showgroups = $db->query_read(" SELECT user.*, userfield.*, usertextfield.*, " . iif($vbulletin->options['avatarenabled'], 'avatar.avatarpath, NOT ISNULL(customavatar.userid) AS hascustomavatar, customavatar.dateline AS avatardateline,customavatar.width AS avwidth,customavatar.height AS avheight,') . " postparsed.pagetext_html, postparsed.hasimages, $hook_showgroups_complete LEFT JOIN " . TABLE_PREFIX . "usertextfield AS usertextfield ON(usertextfield.userid = user.userid) " . iif($vbulletin->options['avatarenabled'], "LEFT JOIN " . TABLE_PREFIX . "avatar AS avatar ON(avatar.avatarid = user.avatarid) LEFT JOIN " . TABLE_PREFIX . "customavatar AS customavatar ON(customavatar.userid = user.userid)") . " "); HTML Code:
if ($this->post['avatarid']) { $this->post['avatarurl'] = $this->post['avatarpath']; } else { if ($this->post['hascustomavatar'] AND $this->registry->options['avatarenabled']) { if ($this->registry->options['usefileavatar']) { $this->post['avatarurl'] = $this->registry->options['avatarurl'] . '/avatar' . $this->post['userid'] . '_' . $this->post['avatarrevision'] . '.gif'; } else { $this->post['avatarurl'] = 'image.php?' . $this->registry->session->vars['sessionurl'] . 'u=' . $this->post['userid'] . '&dateline=' . $this->post['avatardateline']; } if ($this->post['avwidth'] AND $this->post['avheight']) { $this->post['avwidth'] = 'width="' . $this->post['avwidth'] . '"'; $this->post['avheight'] = 'height="' . $this->post['avheight'] . '"'; } else { $this->post['avwidth'] = ''; $this->post['avheight'] = ''; } } else { $this->post['avatarurl'] = ''; } } if ( // no avatar defined for this user empty($this->post['avatarurl']) OR // visitor doesn't want to see avatars ($this->registry->userinfo['userid'] > 0 AND !$this->registry->userinfo['showavatars']) OR // user has a custom avatar but no permission to display it (!$this->post['avatarid'] AND !($this->cache['perms'][$this->post['userid']]['genericpermissions'] & $this->registry->bf_ugp_genericpermissions['canuseavatar']) AND !$this->post['adminavatar']) // ) { $show['avatar'] = false; } else { $show['avatar'] = true; } |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|