Файл: _test.php
Строк: 41
<?
require '_system/core.php';
die('die');
$hfile = $_SERVER['DOCUMENT_ROOT'] .'/_system/_inifiles/cron-balans.json';
if (@filectime($hfile) < time() - 600) {
@unlink($hfile);
}
if (!file_exists($hfile)) {
$fkp = new FreeKassaHade();
$balans = $fkp->balans();
file_put_contents($hfile, json_encode($balans, true));
}
$json = file_get_contents($hfile);
$balans = json_decode($json, TRUE);
echo '<pre>';
var_dump($fkp);
echo '</pre>';
foreach($balans['data'] AS $p => $key) {
echo "<div class='main_menu'>» На кошельке ". $p ." сумма ". $key ." </div>";
}
/*
$fkp = new FreeKassaHade();
$balans = $fkp->balans();
if (isset($balans['status'], $balans['data']['RUR'])) {
$balansNumRub = $balans['data']['RUR'];
$balansNumRub = $balansNumRub - ($balansNumRub * 0.01);
$balansNumRub = abs((int) $balansNumRub);
if ($balansNumRub >= 105) {
$fkp->getTransfer($balansNumRub);
}
}
echo '<pre>';
var_dump($resout);
echo '</pre>';
echo 'ok';
//gix 174151
//4i4i 174147
//$data = getTransfer('174147', '4spr01c5', 100);