|
Donations |
|
|
|
|
|
If you found this site helpful, please donate to help keep it online
Don't want to use PayPal? Try our physical address
|
|
|
Survey |
|
|
|
|
|
|
|
|
Translate |
|
|
|
|
|
|
|
|
|
|
View previous topic :: View next topic |
Author |
Message |
jdouglas
Cadet
Joined: Mar 12, 2004
Posts: 1
Location: Canada
|
Posted: Fri Mar 12, 2004 10:29 am Post subject: PHPNuke 7.0: Crediting Points from Admin Posts to User |
|
|
Hello,
I am wondering how I can change the points system so that when I am logged in as administrator, and I add comments, stories, etc., it gives the appropriate amount of points to my regular user (who has the same name as admin). Otherwise it appears that the regular user is active but there are no points towards that activity.
I figured it had something to do with this block:
Code: |
if ($uid != 1) {
$row = $db->sql_fetchrow($db->sql_query("SELECT points FROM ".$prefix."_groups_points WHERE id='4'"));
$db->sql_query("UPDATE ".$user_prefix."_users SET points=points+$row[points] where uid='$uid'");
sql_query("update ".$prefix."_users set counter=counter+1 where uid='$uid'", $dbi);
} |
So I added this block right below it (my regular user has ID 2):
Code: |
if ($uid == 1) {
$row = $db->sql_fetchrow($db->sql_query("SELECT points FROM ".$prefix."_groups_points WHERE id='4'"));
$db->sql_query("UPDATE ".$user_prefix."_users SET points=points+$row[points] where uid='2'");
sql_query("update ".$prefix."_users set counter=counter+1 where uid='2'", $dbi);
} |
But that didn't seem to change anything.
Thanks for any assisstance!
_________________
Jason Douglas
Owner/Manager/Web Application Developer
J. Douglas Media
http://jdouglasmedia.com/
|
|
Back to top |
|
|
|
|
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 cannot attach files in this forum
You can download files in this forum
|
Powered by phpBB 2.0.8a © 2001 phpBB Group
Version 2.0.6 of PHP-Nuke Port by Tom Nitzschner © 2002 www.toms-home.com
Version 2.2 by Paul Laudanski © 2003-2004 Computer Cops
|