laravel线上和本地用$file= $request->all()获取参数的问题

前台发送的是一个formdata数据 里面有files和json数据 laravel后台这样获取参数的

$file= $request->all();
dd($file);

下面是线上和线下用$request->all()获取到的数据 为什么线上获取到的是三个参数 多了一个当前路由的地址 而本地测试获取到的是两个参数呢?
线上
图片描述

线下
图片描述

nginx配置

server{                                                     
         listen 80;       
         server_name www.domain.com;
         return 301 https://domain.com$uri;
}

server {
    server_name domain.com;
    client_max_body_size 20M;
    listen 443 ssl;
    ssl on;
    ssl_certificate /etc/nginx/ssl/1_domain.com_bundle.crt;
    ssl_certificate_key /etc/nginx/ssl/2_domain.com.key;
    set $root_path '/var/www/html/blog/public';    
    root $root_path;
    index index.php index.html index.htm;
    
    try_files $uri $uri/ @rewrite;  
      
    location @rewrite {  
        rewrite ^/(.*)$ /index.php?_url=/$1;  
    }  

    location ~ \.php {  
      
            fastcgi_pass unix:/run/php/php7.2-fpm.sock;
            fastcgi_index /index.php;  
      
            fastcgi_split_path_info       ^(.+\.php)(/.+)$;  
            fastcgi_param PATH_INFO       $fastcgi_path_info;  
            fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;  
            fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;  
            include                       fastcgi_params;
    }  
        
    location ~* ^/(css|img|js|flv|swf|download)/(.+)$ {    
        root $root_path;    
    }  
    location ~ /\.ht {    
            deny all;    
    }  
}
阅读 3.7k
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题