public function saveFile(Request $request) { $md5Name = md5_file($request->file('your_input_name')->getRealPath()); $guessExtension = $request->file('your_input_name')->guessExtension(); $file = $request->file('your_input_name')->storeAs('your_path', $md5Name.'.'.$guessExtension ,'your_disk'); }

->store() laravel change name

Similar Code Examples