Quote:
Originally Posted by FatalBreeze
Hello!
im trying to build a hack which combine the gender hack and the usertitles in the forum, but i cant seem to find the file that is incharge of changing usertitle when the user has reached a certain amount of posts.
for example if i set a new usertitle by the name of "good member" and change the minimum posts to 100, what file makes the user get the new user title when he reaches 100 posts.
at first i thought it is promotions.php but i guess its not.
Thanks for your help 
|
this is what i found in admincp/user.php
PHP Code:
if ($user['customtitle'] == 0)
{
$usergroup = $DB_site->query_first("
SELECT usertitle
FROM " . TABLE_PREFIX . "usergroup
WHERE usergroupid = $user[usergroupid]
");
if (empty($usergroup['usertitle']))
{
$gettitle = $DB_site->query_first("
SELECT title
FROM " . TABLE_PREFIX . "usertitle
WHERE minposts <= $user[posts] + 1
ORDER BY minposts DESC
");
$user['usertitle'] = $gettitle['title'];
}
else
{
$user['usertitle'] = $usergroup['usertitle'];
}
}