博客
关于我
PHP二维数组转换为一维数组
阅读量:793 次
发布时间:2023-03-01

本文共 459 字,大约阅读时间需要 1 分钟。

二维数组转换为一维数组的方法示例

二维数组转换为一维数组的方法示例

            // 二维数组转换为一维数组            function getArray($arr) {                static $result = array();                foreach ($arr as $key => $value) {                    if (is_array($value)) {                        getArray($value);                    } else {                        $result[] = $value;                    }                }                return $result;            }        

转载地址:http://zctfk.baihongyu.com/

你可能感兴趣的文章
php curl_multi批量发送http请求
查看>>
php curl请求微信发红包接口出现错误:Peer's Certificate issuer is not recognized.
查看>>
PHP curl请求错误汇总和解决方案
查看>>
php declare(ticks=1)
查看>>
UVA 10474
查看>>