【发布时间】:2015-01-02 19:04:09
【问题描述】:
$doSetupQ = http_build_query(
array(
"doSetup" => $doSetup
)
);
$opts = array('http' =>
array(
'method' => 'POST',
'header'=> "Content-type: application/x-www-form-urlencoded",
'content' => $doSetupQ
)
);
$context = stream_context_create($opts);
// call script to address V3
$path = "http://localhost/" . WWWBASE_V3 . "bin/doApi.php?company_id=" . $_SESSION['company_id'];
$returnDoApi = file_get_contents($path, false, $context);
$returnDoApi = unserialize($returnDoApi);
return $returnDoApi;
我有上面的代码。 在 doApi 脚本上,我只收到数组的一部分。(总是停在同一个元素处(也在子数组的中间。 (使用 curl 相同的问题) 可能有一些 memory_limit 左右,但找不到哪个。
【问题讨论】:
-
在中途停止之前读取了多少数据?
-
有错误吗?警告?
标签: php file-get-contents