Answer the question
In order to leave comments, you need to log in
How to get data via json?
hello i have this php code
$proigr = array(
'z_1'=>0,
'z_2'=>rand(0, 1),
'z_3'=>rand(0, 1),
'z_4'=>rand(0, 1),
'z_5'=>rand(0, 1),
'z_6'=>rand(0, 1),
'z_7'=>rand(0, 1),
'z_8'=>rand(0, 1),
'z_9'=>rand(0, 1),
);
echo json_encode($proigr);
Answer the question
In order to leave comments, you need to log in
So you seem to be doing everything right. So you need to convert the array to JSON.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question