Answers for "->store() laravel change name"

PHP
0

->store() laravel change name

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');
}
Posted by: Guest on January-22-2021

Code answers related to "->store() laravel change name"

Browse Popular Code Answers by Language