Home > Backend Development > PHP Tutorial > php接收post文件有关问题

php接收post文件有关问题

WBOY
Release: 2016-06-13 12:44:52
Original
789 people have browsed it

php接收post文件问题
vc客户端使用http post abc.txt文件给php server端,server端收到的abc.txt文件是空的,是不是php://input问题呢,请高手指教。谢谢!

vc客户端:
Content-Disposition: form-data; name="upload"; filename="abc.txt"
Content-Type: text/plain


php server端:
$input = file_get_contents('php://input');
file_put_contents('abc.txt',$input);
?>

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template