From::JSON()

Decodes JSON string to data.

Table of Contents
  1. Description
  2. Example

Description

From::JSON(?string $value, bool $array = false): mixed;

This method decodes JSON string to PHP data so that it can be processed as native array/object data.

Example

$value = From::JSON('{"a":1,"b":2,"c":3,"d":4,"e":5}');

foreach ($value as $k => $v) {
    echo $k . ': ' . $v . '<br>';
}

From::JSON()

Decodes JSON string to data.

From::entity()

Converts HTML entities to their corresponding characters.