时间:2021-07-01 10:21:17 帮助过:6人阅读
function ext_json_decode($str, $mode=false){
if(preg_match('/\w:/', $str)){
$str = preg_replace('/(\w+):/is', '"$1":', $str);
}
return json_decode($str, $mode);
}function ext_json_decode($str, $mode=false){
$str = trim( $str );
$str = ltrim( $str, '(' );
$str = rtrim( $str, ')' );
$a = preg_split('#(?
以上就介绍了php解决key没有双引号的问题,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。