Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Ravens PHP Scripts And Web Hosting Forum Index -> phpnuke 7.1
Author Message
nuk3r
New Member
New Member


Joined: Dec 19, 2003
Posts: 18

PostPosted: Sat Feb 28, 2004 6:29 pm Reply with quote

hi
i have been trying to streamline my points sytem on my nuke7.1 site.
I have another module that uses points (FriendFinder) and ive changed the code so that the Friendfinder module points are combined with the Nuke site points.
Ive installed a new Userinfo_block that shows top users points and Groups+how many points you need to be a member of that group.
The points are all combined but it shows the MEMBER group(need 1 point for this group)as only having 3 users in that group?
There is 10 members with over 50 points?
Do i have to alter the points code elsewhere in order for them to be put into these groups?
Here is the change ive made in the mainfile.php for points
Code:
function update_points($id) { 

    global $user_prefix, $prefix, $db, $user;
    if (is_user($user)) {
   if(!is_array($user)) {
       $user1 = base64_decode($user);
       $user1 = explode(":", $user1);
           $username = "$user1[1]";
   } else {
           $username = "$user1[1]";
   }
   if ($db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_groups")) > 0) {
       $row = $db->sql_fetchrow($db->sql_query("SELECT points FROM ".$prefix."_groups_points WHERE id='$id'"));
       //remove // in the next line if you want to use points in normal nuke system.
       //$db->sql_query("UPDATE ".$user_prefix."_users SET points=points+$row[points] WHERE username='$username'");
       $db->sql_query("UPDATE ".$user_prefix."_user_profile2 SET points=points+$row[points] WHERE ffusername='$username'");
   }
    }
}


im a bit confused with the points system,in the forums there is usergroups wich i assume would put a user into a group for the forums?
Then there is users groups wich would put users into groups for subscriptions?
Embarassed
 
View user's profile Send private message
Display posts from previous:       
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Ravens PHP Scripts And Web Hosting Forum Index -> phpnuke 7.1

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©