小程序上传视频,PHP怎么接收不到?

直接看代码:

 wx.chooseVideo({
      success(res) {
        const tempFilePaths = res.tempFilePath
        console.log(res);
        wx.uploadFile({
          url: 'https://XXX.upload.php', //仅为示例,非真实的接口地址
          filePath: tempFilePaths,
          name: 'file',
          formData: {
            'user': 'test'
          },
          header: {
            'content-type': 'multipart/form-data'
          },
          success(res) {
            console.log("#")           
          }

后台代码:

 if(!empty($_FILES['file'])){
    echo "#";
}else{
    echo "NULL";
}

var_dump($_POST);
var_dump($_FILES);

结果NULL ARRAY(0){} ARRAY(0){}
便是换为chooseImage那个函数可以返回图片信息?上传视频一直返回为空要怎么接收?谢谢

https://blog.csdn.net/futruejet/article/details/53380191