Answer the question
In order to leave comments, you need to log in
Get array in js via ajax?
Hi guys.
A question.
There is a statistic.php page where I output an array in json
{"col_day":"525","day_budjet":"3906060","col_mount":"525","day_budjet_mount":"3906060"}
Answer the question
In order to leave comments, you need to log in
JSON.parser takes a string and makes an object/array out of it, in your case it's an object.
If you use jQuery to perform ajax requests, then it will be enough to specify dataType: "json" and the result will immediately be in the form of an object.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question