I have something like that :
In my controller , I wrote this line :
dd($file->path);
and here is result :
UploadedFile {#294
-test: false
-originalName: "photo.png"
-mimeType: "image/png"
-size: 319216
-error: 0
path: "/tmp"
basename: "phpLJA6Ge"
pathname: "/tmp/phpLJA6Ge"
}
I want to return .png . How to retrieve originalName?