cannot use object of type stdClass as array ——PHP

分析缘由:php js传过来的字符串数据 .php接收后转换为数组对象 $output = json_decode($cc);json 结果不完全,里面的是个字符串对象。不能使用。故而报错:数组 Cannot use object of type stdClass as arrayspa 解决方法:code 两种对象 使用 json_decode($d, true)。就是使json_decode
相关文章
相关标签/搜索