php - Laravel - moving file causing error -
i trying copy file 1 directory follows:
$files = file::allfiles($temp); foreach ($files $f) { $f->move($destination, file::name($f)); }
i getting error:
call undefined method symfony\component\finder\splfileinfo::move()
in following line: $f->move($destination, file::name($f));
it seems not detect $f being of type file because every time try , use of functions getclientoriginalname()
i error.
i keep getting error. seems not registering $f being file..
also thing keep in mind don't know name of file why of files in directory (only ever 1 @ time)
try this:
file::get($f)
let me know happens.