我在这里有这个 PHP 代码:
$info = array();
if($this->build) {
$info['price_type'] = 'build';
} else if($this->zip) {
$info['is_co'] = r_check_is_co_zip($this->zip);
$info['idS'] = r_find_ids_near($this->zip);
etc etc....
}
$f = fopen(CORE_ROOT . '/../pc/debuging.txt', 'a');
fwrite($f, "***ZIPCode DEBUG***" . "\r\n");
fwrite($f, "*date/time: " . date("F j, Y, g:i a") . "*" . "\r\n");
foreach($info as $q) {
fwrite($f, $q . "\r\n");
}
fwrite($f, "***************************" . "\r\n");
fclose($f);
当我尝试遍历数组以获取$info时,除了"Array"之外,我什么也没得到。我可能做错了什么?