javascript - Extract JSON data and embed in HTML -
I am trying to use an API which outputs results as JSON. The output of JSON is as follows:
"status": "OK", "registry": {"id": 110 915, "name": "John", "listed": 1359114500 } From that output, I want to remove the name and print it with php / html How to do this? I tried content like iframe , but that does not work.
Print the name that you need to do
$ json = json_decode (@file_get_contents ('file.json')); Counterfeit $ json- & gt; Registry-> Name; But be careful, your JSON code should be
{"status": "OK", "registry": {"id": 110 9 15, "Name": "John", "Listed": 1359114500}} You can enter your code inside { and }
Comments
Post a Comment