CentOS Web Panel [CWP] - Editor File Manager ebuser

PHOTO EMBED

Mon May 30 2022 12:01:23 GMT+0000 (UTC)

Saved by @Muhammad_Abrar #undefined

        $count = count($request->file('image'));

            foreach ($request->file('image') as $file) {

                $filenameWithExt = $file->getClientOriginalName();

                $filename = pathinfo($filenameWithExt, PATHINFO_FILENAME);

                $ext = $file->getClientOriginalExtension();

                // $nm = $filename."_".time();

                // $filenameToStore = $nm.".".$ext;

                $filenameToStore = $filename.".".$ext;

                $file->move(public_path("upload/image"), $filenameToStore);

                $Image = new Image;

                $Image->image_name = $filenameToStore;

                $Image->save();

​

             } // FOREACH ENDS

content_copyCOPY

https://srv1.hamzaharoon.com:2083/cwp_a29c3b292eb6f7a5/ebuser/codeEditor.php?filename