vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Points for posts and reffering new members - system (https://vborg.vbsupport.ru/showthread.php?t=50693)

Fking 03-23-2003 08:40 AM

Points for posts and reffering new members - system
 
I want to give points to my members
e.g. 1 point for 1 post and 5 points for referred member.
And when they reach some count, I'll give them prizes

I made a little search but I didn't find exactly that, sorry if I'm asking for something already well-known.

Thanks.

Fking 03-26-2003 04:57 PM

Eho?

Rose 03-26-2003 05:13 PM

I would recommend the Store hack by Lesane or any of the "points" hacks which should be able to easily customize the points given for new posts/newthreads/replies/referrals/etc.

Fking 03-26-2003 06:20 PM

Quote:

Today at 07:13 PM Rose said this in Post #3
I would recommend the Store hack by Lesane or any of the "points" hacks which should be able to easily customize the points given for new posts/newthreads/replies/referrals/etc.

Where to find it?

g-force2k2 03-26-2003 06:32 PM

Fking open register.php find:

PHP Code:

        if (!$testreferrerid=$DB_site->query_first("SELECT userid FROM user WHERE username = '".addslashes($referrername)."'")) {
          eval(
"standarderror(\"".gettemplate("error_badreferrer")."\");");
          exit;
        } 

under it add:

PHP Code:

else {
        
$DB_site->query"UPDATE user SET points=points+5 WHERE userid='$testreferrerid[userid]'" );
      } 

the open both newreply.php and newthread.php and find:

PHP Code:

          $dotitle"."lastpost='".time()."' WHERE userid='$bbuserinfo[userid]'"); 

and replace with:

PHP Code:

          $dotitle"."lastpost='".time()."',points=points+1 WHERE userid='$bbuserinfo[userid]'"); 

then run the query:

ALTER TABLE user ADD points int(5) unsigned NOT NULL DEFAULT '0'

you can then add to the postbit template $post[points] to show points and to the getinfo template $userinfo[points]...

hope that helps some...

regards...

g-force2k2


All times are GMT. The time now is 03:56 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.00922 seconds
  • Memory Usage 1,728KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete