Thread: PHP Code.
View Single Post
  #1  
Old 08-29-2012, 06:36 PM
Aasixx's Avatar
Aasixx Aasixx is offline
.. your friendly geek. c:
 
Join Date: Nov 2011
Location: somewhere ur not.
Posts: 191
Gender: Female
Credits: 27,482
Aasixx is on a distinguished road
Default PHP Code.

Well, I'm using Derpstra's wonderful PHP code (thank you for posting it, Derpstra!) and I was wondering if there was a way to make it where you cannot refresh that page or go back. I'm using this page for when they purchase a certain amount of cash for real money that they're sent to this page to automatically gain their purchased cash. But, I noticed, when you refresh/press go back, they can easily cheat and gain a lot of cash for free. I want to make it where they cannot cheat. Is this possible?

Code:
PHP Code:
<?php

include("functions/functions.php");
include(
"functions/functions_users.php");
include(
"functions/functions_adopts.php");
include(
"functions/functions_friends.php");
include(
"functions/functions_items.php");
include(
"inc/lang.php");
include(
"inc/bbcode.php");

//***************//
// START SCRIPT //
//***************//

$cashname grabanysetting("cost");
$reward1;

if(
$isloggedin == "yes"){
changecash($reward$GLOBALS['username'], $GLOBALS['money']);
$article_title "Hello, {$username}!";
$article_content "You have gained {$reward} {$cashname}.";
}
else{
$article_title "You are not logged in!";
$article_content "You must be logged in to view this page!";
}

//***************//
// OUTPUT PAGE //
//***************//

echo showpage($article_title$article_content$date);
?>
__________________
Reply With Quote