app/Http/Controllers/SectionsController.php
/**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
Store a newly created resource in storage.
Store a newly created resource in storage .
public function store(Request $request)
    {
       $request->validate([
        'section_name' => 'required',
    ]);
    Sections::create($request->all());
        return redirect()->route('section.index')->with('success','One Row Inserted Successfully');
    }
public function store ( Request $ request ) { $ request -> validate ( [ 'section_name' => 'required' , ] ) ; Sections :: create ( $ request -> all ( ) ) ; return redirect ( ) -> route ( 'section.index' ) -> with ( 'success' , 'One Row Inserted Successfully' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .