pageLoadTimeStart(); ################################################################################# ## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ## ## --------------------------------------------------------------------------- ## ## Project: TravianZ ## ## Version: 18.05.2026 ## ## Filename: a2b2.php ## ## Developed by: Dzoki ## ## Refactored by: Shadow ## ## License: TravianZ Project ## ## Copyright: TravianZ (c) 2010-2026. All rights reserved. ## ## URLs: https://travianz.org ## ## https://github.com/Shadowss/TravianZ ## ## ## ################################################################################# use App\Utils\AccessLogger; include_once("GameEngine/Village.php"); AccessLogger::logRequest(); $uid = (int)$session->uid; $amount = (int)($_SESSION['amount'] ?? 0); $packages = [ 199 => 60, 499 => 120, 999 => 360, 1999 => 1000, 4999 => 2000 ]; if (isset($_GET['newdid'])) { $_SESSION['wid'] = (int)$_GET['newdid']; header("Location: a2b2.php"); exit; } $building->procBuild($_GET); $transactionProcessed = false; $oldBalance = 0; $newBalance = 0; $goldAdded = 0; if (isset($packages[$amount]) && $amount > 0) { $goldAdded = $packages[$amount]; $result = mysqli_query($database->dblink, "SELECT gold FROM " . TB_PREFIX . "users WHERE id = $uid LIMIT 1"); $user = mysqli_fetch_assoc($result); $oldBalance = (int)$user['gold']; mysqli_query($database->dblink, "UPDATE " . TB_PREFIX . "users SET gold = gold + $goldAdded WHERE id = $uid"); $result = mysqli_query($database->dblink, "SELECT gold FROM " . TB_PREFIX . "users WHERE id = $uid LIMIT 1"); $user = mysqli_fetch_assoc($result); $newBalance = (int)$user['gold']; $transactionProcessed = true; $_SESSION['amount'] = 0; } ?>
Thank you for your purchase here at .
Below you see the entry record. Out of it, you can observe your old as well as your new account balance.
| Record of | ||||
|---|---|---|---|---|
| Description | ![]() |
Action | ![]() |
Date |
| Account Balance (old) | ||||
Package |
Gold |
|||
| Account Balance (new) | ||||
Please verify the information.
It will let us know if the data is incorrect.
Please mail your username, package, order time and email used to our billing address.
dblink, "SELECT gold FROM ".TB_PREFIX."users WHERE id = $uid LIMIT 1"); $golds = mysqli_fetch_assoc($result); $stats = mysqli_fetch_assoc(mysqli_query($database->dblink, " SELECT SUM(CASE WHEN gold > 0 THEN gold ELSE 0 END) as received, SUM(CASE WHEN gold < 0 THEN -gold ELSE 0 END) as spent FROM ".TB_PREFIX."gold_fin_log WHERE uid = $uid ")); $received = (int)($stats['received'] ?? 0); $spent = (int)($stats['spent'] ?? 0); ?>Here you can see your current account statement.
Current balance:
| Total received: +
| Total spent: -
| Gold history | |||||
|---|---|---|---|---|---|
| Date & Time | Village | Action | Details |
|
Balance |
'.$date.' | ';
echo ''.$villageName.' | ';
echo ''.$action.' | ';
echo ''.$details.' | ';
echo ''.$sign.$gold.' | ';
echo ''.$balance.' | ';
echo '
|
No transactions yet.
|
|||||
Please verify the information.
It will let us know if the data is incorrect.
Please mail your username, package, order time and email used to our billing address.