$_FILES一直为空数组,enctype=”multipart/form-data”也有,把post改成POST就行了,大小写很关键!
标准写法
<!– 上传文件一定要写 enctype=”multipart/form-data” –>
<form enctype=”multipart/form-data” action=”__URL__” method=”POST”>
<!– Name of input element determines name in $_FILES array –>
Send this file: <input name=”userfile” type=”file” />
<input type=”submit” value=”Send File” />
</form>
来源”:http://lhdeyx.blog.163.com/blog/static/3181969720118110310863/