Ummm....hehe...my bad.
The points are added with the following code in newreply.php:
Quote:
$DB_site->query("UPDATE user SET
".iif (($forumid==19) and (!$bbuserinfo[userid]==$threadinfo[postuserid]),"rating=rating+2,","")."
$dotitle"."lastpost='".time()."' WHERE userid='$bbuserinfo[userid]'");
|
IF forum is 19 and poster is NOT thread starter, add 2 to rating
I was trying using similar code to do the change of usergroups:
Quote:
$DB_site->query("UPDATE user SET
".iif (($bbuserinfo[rating]==20) and ($bbuserinfo[usergroupid]==2),"usergroupid=10,","")."
$dotitle"."lastpost='".time()."' WHERE userid='$bbuserinfo[userid]'");
|
IF users rating IS 20 AND user is noob THEN change usergroup to full member
It's a little messy, and it doesn't need to also set the last post bits, but putting it here means that on the 10th reply when rating=20 I was hoping usergroupid would change from 2 to 10 automatically to open up an extra forum for example, different user title, etc. I'm doing something completely wrong aren't I? It's blatantly obvious isn't it? Hehe.