app/Http/Controllers/Admin/TestimonialController.php
/**
     * Remove the specified resource from storage.
     *
     * @param  \App\Models\Testimonial  $testimonial
     * @return \Illuminate\Http\Response
     */
Remove the specified resource from storage.
Remove the specified resource from storage .
public function destroy(Testimonial $testimonial)
    {
        $testimonial->delete();
        if(file_exists(public_path('storage/testimonial/' . $testimonial->t_image))){
            unlink(public_path('storage/testimonial/' . $testimonial->t_image));
        }
        return redirect(route('admin.testimonial.index'))->with('success','Testimonial successfully Delete.');
    }
public function destroy ( Testimonial $ testimonial ) { $ testimonial -> delete ( ) ; if ( file_exists ( public_path ( 'storage/testimonial/' . $ testimonial -> t_image ) ) ) { unlink ( public_path ( 'storage/testimonial/' . $ testimonial -> t_image ) ) ; } return redirect ( route ( 'admin.testimonial.index' ) ) -> with ( 'success' , 'Testimonial successfully Delete.' ) ; }
Remove the specified resource from storage.
Remove the specified resource from storage .