Jump to content


Where should I look??

  • This topic is locked This topic is locked
2 replies to this topic

#1 graciehz

  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 21 June 2006 - 08:07 PM

I'm currently putting together a virtual pet site. I need my users to collect gold as the browse thru the pages on the site. Example: User clicks on Games. 10 Gold is automatically added to their account. I'm not sure where I should start to look in putting in something extra like that into the script. I see that my global.inc.php shows this refering to getting the users current points in the database:
[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]$username = $getInfo[username];
$display_name = $getInfo[display_name];
$userid = $getInfo[id];
$points = $getInfo[points];
$rank = $getInfo[rank];
$hungerLevel = $getInfo[hunger_level];

if (!$username) { $username = "<i>Not logged in.</i>"; }
if (!$display_name) { $display_name = "<i>Not logged in.</i>"; }
if (!$points) { $points = "0"; }[/quote]
I'm sort of thinking it can be done in one of these scripts that I have or maybe their should be a seperate script telling points to be added upon every click by the user??? I'm sort of lost. Could someone help me out.

#2 Renlok

  • Members
  • PipPipPip
  • Advanced Member
  • 258 posts
  • Locationnewbury

Posted 02 February 2007 - 12:44 PM

that all looked really unnessasary all you need is to check the loggin cookie is set with valid data then update the users table with +10 gold/points we you call it

#3 wildteen88

  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 02 February 2007 - 06:26 PM

Whoa! Why have you bumped a topic that was posted 6 months or so a go

Topic closed.

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users