Snippets tagged “json-decode”
11 snippets use this tag.
- Guzzle 6: no more json() method for responsesPHP
In Guzzle 6, the json() method for parsing JSON responses has been removed.
- How to convert a string to JSON object in PHPPHP
You can use the json_decode function in PHP to convert a JSON string into a PHP object.
- How to Create and Parse JSON Data with PHPPHP
JSON is a data-interchange format, which can be generated and parsed by PHP or other programming languages. See how to create and parse JSON data by PHP.
- How to decode Unicode escape sequences like "\u00ed" to proper UTF-8 encoded characters?PHP
In PHP, you can use the utf8_decode() function to decode a string that contains Unicode escape sequences.
- How to Fix the Uncaught Error "Cannot Use Object of Type stdClass as an Array"PHP
This short tutorial is dedicated to a common PHP issue "cannot use object of Type stdClass as an array". Read on to find the most accurate solutions.
- How to JSON Decode a String into an Array with PHPPHP
This is a short guideline that provides comprehensive information on how to decode a JSON string into an array with the help of PHP.
- Issue reading HTTP request body from a JSON POST in PHPPHP
In PHP, you can read the body of an HTTP request using the file_get_contents('php://input') function.
- json_decode to custom classPHP
In PHP, you can use the json_decode() function to convert a JSON string into a PHP object or array.
- PHP Fatal error: Call to undefined function json_decode()PHP
This error usually occurs when you are trying to use the json_decode() function, which is used to decode a JSON string into a PHP variable, but the function is not available.
- PHP json_decode() returns NULL with seemingly valid JSON?PHP
There are a few possible reasons that json_decode() might return NULL when given what appears to be valid JSON.
- Save PHP array to MySQL?PHP
To save a PHP array to a MySQL database, you can use the serialize() function to convert the array into a string, and then use an INSERT or UPDATE statement to save the string into a TEXT or LONGTEXT field in the database.