"101010100","海淀"=>"101010200","朝阳"=>"101010300"); foreach ($citycode as $arr) { echo $ar">
时间:2021-07-01 10:21:17 帮助过:22人阅读
"101010100","海淀"=>"101010200","朝阳"=>"101010300");foreach ($citycode as $arr => $value) { $citycode[$arr] .= ',';}// saveFile('file.txt',$arr);file_put_contents('file.txt', $citycode);?>
这样岂不是更简单
$arr = implode(',', $citycode);saveFile('file.txt',$arr);
这样岂不是更简单
$arr = implode(',', $citycode);saveFile('file.txt',$arr);
$citycode = array("北京"=>"101010100","海淀"=>"101010200","朝阳"=>"101010300");saveFile('file.txt',implode(',',$citycode));
其实我就是在想jordan102的,我写JS写多了,脑子尽然一天没转过弯来。