Basheer H. Basheer H. - 1 year ago 84
JSON Question

Display json data in PHP from API using GET

I have API url looks like this:

when I click on it I got the following data:


How to display and format the response data in PHP page using GET method?

Answer Source

json_decode() is what you are looking.

$link = "your url"

$data = json_decode($link,true);

after decoding the json, you will get a array with the elements in the json

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download