Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有这样的数据$fields = array('0001','0002','0003','00004');
$fields = array('0001','0002','0003','00004');
我需要将这些数据放入 csv 文件中,我使用:
$fp = fopen('file.csv', 'w'); fputcsv($fp, $fields);
但是当file.csv在 excel 中打开时,开始的空值 (0) 被删除,我看到这样的数据
file.csv
1|2|3|4
如何在 csv 文件中存储起始空值?