• <kbd id="qyk40"></kbd>
  • <strike id="qyk40"></strike><samp id="qyk40"><pre id="qyk40"></pre></samp>
     
    function iterTree($data) {
        $retData = array();
        $data = json_decode($data, true);
        if (!is_array($data) && empty($data)) {
            echo 'error !' . "\n";
        } else {
            $queue = array();
            foreach ($data as $field => $value) {
                $queue[] = $field;
            }      
            $head = 0;
            $tail = count($queue);
            while ($head < $tail) {
                $field = $queue[$head++];
                $path = explode("/", $field);
                $tmpData = &$data;
                foreach ($path as $key => $ph) {
                    $tmpData = &$tmpData[$ph];
                }      
                if (is_array($tmpData) && !empty($tmpData)) {
                    $newField = $field;
                    foreach ($tmpData as $curField => $curValue) {
                        $newField = $field . '/' . $curField;
                        $queue[$tail++] = $newField;
                    }      
                } else {
                    $retData[] = $field;
                }      
            }      
        }
        return $retData;
    }
     
    //測試數(shù)據(jù)
    $data = file_get_contents("http://restapi.ele.me/v1/restaurants?extras%5B%5D=food_activity&extras%5B%5D=restaurant_activity&extras%5B%5D=certification&fields%5B%5D=id&fields%5B%5D=name&fiel
    ds%5B%5D=phone&fields%5B%5D=promotion_info&fields%5B%5D=name_for_url&fields%5B%5D=flavors&fields%5B%5D=is_time_ensure&fields%5B%5D=is_premium&fields%5B%5D=image_path&fields%5B%5D=rating&fie
    lds%5B%5D=is_free_delivery&fields%5B%5D=minimum_order_amount&fields%5B%5D=order_lead_time&fields%5B%5D=is_support_invoice&fields%5B%5D=is_new&fields%5B%5D=is_third_party_delivery&fields%5B%
    5D=is_in_book_time&fields%5B%5D=rating_count&fields%5B%5D=address&fields%5B%5D=month_sales&fields%5B%5D=delivery_fee&fields%5B%5D=minimum_free_delivery_amount&fields%5B%5D=minimum_order_des
    cription&fields%5B%5D=minimum_invoice_amount&fields%5B%5D=opening_hours&fields%5B%5D=is_online_payment&fields%5B%5D=status&fields%5B%5D=supports&fields%5B%5D=in_delivery_area&geohash=wx4g07
    j0w1v7&is_premium=0&limit=1000&offset=24&type=geohash");
     
    $ret = iterTree($data);

    穩(wěn)定

    產(chǎn)品高可用性高并發(fā)

    貼心

    項(xiàng)目群及時溝通

    專業(yè)

    產(chǎn)品經(jīng)理1v1支持

    快速

    MVP模式小步快跑

    承諾

    我們選擇聲譽(yù)

    堅持

    10年專注高端品質(zhì)開發(fā)
    • 返回頂部
    精品久久久久久无码中文野结衣| 自怕偷自怕亚洲精品| 精品3d动漫视频一区在线观看| 国产美女精品人人做人人爽| 99久久国产亚洲综合精品| 久久99精品久久久久婷婷| 久久机热re这里只有精品15| 亚洲精品无码av人在线观看| 精品露脸国产偷人在视频| 午夜精品久久久久久影视777| 亚洲性色AV日韩在线观看| 国产亚洲精品精品精品| 精品国产精品国产| 色妞WWW精品免费视频| 久久精品a一国产成人免费网站| 久久精品极品盛宴观看| 国产精品电影在线观看| 精品国产一区二区三区麻豆| 蜜臀98精品国产免费观看| 精品人妻中文av一区二区三区| 久久亚洲国产成人精品性色| 亚洲AV成人精品网站在线播放| 久久精品视频一区二区三区| 久久精品一区二区三区不卡| 亚洲色精品aⅴ一区区三区| 国产亚洲美女精品久久久2020| 99精品久久精品| 中文无码久久精品| 国产在视频线精品视频二代| 亚洲精品国精品久久99热一| 亚洲精品乱码久久久久久久久久久久 | 55夜色66夜色国产精品视频| porn在线精品视频| 国内精品自线在拍2020不卡| 日韩欧美亚洲国产精品字幕久久久 | 久久久精品天堂无码中文字幕| 亚洲精品无码专区久久| 精品无码国产一区二区三区51安| 国语自产精品视频在线看| 国产精品国语对白露脸在线播放| 日韩大片在线永久免费观看网站|