app/Http/Controllers/PostsController.php
/**
     * Store a newly created resource in storage.
     *

     */
Store a newly created resource in storage.
Store a newly created resource in storage .
public function store(Request $request)
    {
        $res = new Post;
        $res -> name = $request->input('name');
        $res -> address = $request->input('address');
        $res -> organization = $request->input('organization');
        $res -> email = $request->input('email');
        $res -> image = $request->input('image');
        $res -> save();
        $request-> session()-> flash ('msg','data submitted');
        return redirect('dashboard');
    }
public function store ( Request $ request ) { $ res = new Post ; $ res -> name = $ request -> input ( 'name' ) ; $ res -> address = $ request -> input ( 'address' ) ; $ res -> organization = $ request -> input ( 'organization' ) ; $ res -> email = $ request -> input ( 'email' ) ; $ res -> image = $ request -> input ( 'image' ) ; $ res -> save ( ) ; $ request -> session ( ) -> flash ( 'msg' , 'data submitted' ) ; return redirect ( 'dashboard' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .