0

嗨,我创建了一个将soaprequest 发送到soapserver 的php 脚本。肥皂服务器制作了一个我想取回的文件。

我可以创建文件,但到目前为止我需要将它保存在服务器上。

这是我的代码示例:

//  creating some variables for the files i receive from the soap server
$timeStamp  = Time();
$msgFile        .= 'hpoutput/'. $timeStamp . '_messageFile.txt';
$dlfFile        .= 'hpoutput/'. $timeStamp . '_'. $array["return"]["files"]["fileName"];

// saving the messagefile to the server
$var_str    = var_export($array["return"]["engineMessage"], true);
file_put_contents($msgFile, $var_str);

// saving the actual output file to the server 
$var_str    = serialize($array["return"]["files"]["fileOutput"]);
file_put_contents($dlfFile, $var_str);

问题: - 我可以将创建的文件直接发送到浏览器,而不将其保存在服务器上吗?- 如果这不可能,我怎样才能删除(清理)我的临时空间?

4

0 回答 0