From 9b618abd14b69bd56e64bd998de8f9ccb722fba7 Mon Sep 17 00:00:00 2001 From: piernov Date: Sun, 24 Apr 2016 22:15:52 +0200 Subject: json_encode() PHP gold amount sent to client --- inc/mine.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/mine.inc b/inc/mine.inc index aea04ad..4293243 100644 --- a/inc/mine.inc +++ b/inc/mine.inc @@ -8,7 +8,7 @@ function withdrawMine() { $amount = intval($_POST["amount"]); if($amount == 0) return; $_SESSION["mine"]["gold"] += $amount; - echo $_SESSION["mine"]["gold"]; + echo json_encode($_SESSION["mine"]["gold"]); } function sendMine() { -- cgit v1.2.3-70-g09d2