Get data from JSON file with PHP

Get the content of the JSON file using:


Definition and Usage

The file_get_contents() reads a file into a string.

This function is the best way to read the contents of a file into a string. It uses memory mapping if this technique is supported by the web server enhance performance.

Example completed:

[snippet slug=file_get_contents lang=php]

Rate this post