如何使用PHP实现这一目标?任何解码都返回空值。有人能告诉我一个如何分割每一行并解码每一行的例子吗?
JSON:https://codeshare.io/2BD4ma
添加了一些代码:
$jsonFile = file_get_contents('feeds/quotes.json');
$str = $jsonFile;
$arr = explode("\n", $str);
foreach ($arr as $key => $value) {
// $arr[3] will be updated with each value from $arr...
echo "{$key} => {$value} ";
}
如何获取每个值?