Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Re: [Robert_B] plugin to calculate "points" for users

Quote Reply
Re: [Robert_B] plugin to calculate "points" for users In reply to
Hi,

If you are trying to do this on a "static" site, there are a few ways to go about this, without dragging your system performance down.

One way is to run it as a cron job.

Once a day, or on a very active site, maybe every 4-6 hours.

The other way is to run it when a user actually contributes something. Linkit to the submit_success page that is shown to the user, and give them their current "stats" after each submission. It *should* be current all the time with this, but only updated when it has to update. You wouldn't need any hooks, just simply call the global to run on that users contributions and update their stats with a global call in the _success template.

The only time points are updated is when a user submits something, so this would be the most efficient way.


PUGDOG´┐Ż Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.
Subject Author Views Date
Thread plugin to calculate "points" for users Robert_B 3354 Jun 30, 2006, 3:08 PM
Thread Re: [Robert_B] plugin to calculate "points" for users
rascal 3284 Jun 30, 2006, 8:49 PM
Thread Re: [rascal] plugin to calculate "points" for users
Robert_B 3233 Jul 3, 2006, 4:51 PM
Post Re: [Robert_B] plugin to calculate "points" for users
fuzzy logic 3230 Jul 3, 2006, 6:52 PM
Post Re: [Robert_B] plugin to calculate "points" for users
afinlr 3180 Jul 19, 2006, 10:45 AM
Post Re: [Robert_B] plugin to calculate "points" for users
pugdog 3166 Jul 19, 2006, 2:21 PM