Php drupal_http_请求,http->;数据添加字符串";2000年“;随机排列

Php drupal_http_请求,http->;数据添加字符串";2000年“;随机排列,php,csv,stream,drupal-7,http-headers,Php,Csv,Stream,Drupal 7,Http Headers,我有一个奇怪的问题,我从url获得了一个巨大的CSV文件,带有drupal\u http\u请求: $http = drupal_http_request($url, array('timeout' => 120.0)); file_put_contents(drupal_realpath('public://').'/httpdata.csv',$http->data); 我设法处理它,但当我处理http->data时,我有一些字符串“2000”会断行: 2017-01-09,t

我有一个奇怪的问题,我从url获得了一个巨大的CSV文件,带有
drupal\u http\u请求

$http = drupal_http_request($url, array('timeout' => 120.0));
file_put_contents(drupal_realpath('public://').'/httpdata.csv',$http->data);
我设法处理它,但当我处理
http->data
时,我有一些字符串“2000”会断行:

2017-01-09,toto,tata,31
2017-01-09,toto,ti
2000
ti,34
2017-01-09,toto,tutu,36
[等等]

当我从浏览器直接下载csv并将其打开到Excel或Notepad++时,我没有字符串“2000”,所以我假设drupal_http_请求是有罪的,但我不明白为什么?

(代表OP发布)

我解决了我的问题,用我自己的curl请求替换drupal\u http\u请求,一切都很好

(代表OP发布)

我解决了我的问题,用我自己的curl请求替换drupal\u http\u请求,一切都很好