app/Http/Controllers/enquiriesController.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(EnquiryDataRequest $request)
    {
        $user_id = Auth::user()->id;
        $Enquiry=new Enquiries;
        $Enquiry->customer_id=$user_id;
        $Enquiry->message=$request->get('message');
        $Enquiry->contactNo=$request->get('contactNo');
        $Enquiry->save();
        \Session::flash('flash_message','Successfully Sent'); 
        return redirect()->back();
    }
public function store ( EnquiryDataRequest $ request ) { $ user_id = Auth :: user ( ) -> id ; $ Enquiry = new Enquiries ; $ Enquiry -> customer_id = $ user_id ; $ Enquiry -> message = $ request -> get ( 'message' ) ; $ Enquiry -> contactNo = $ request -> get ( 'contactNo' ) ; $ Enquiry -> save ( ) ; \ Session :: flash ( 'flash_message' , 'Successfully Sent' ) ; return redirect ( ) -> back ( ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .
//<--FLASH MESSAGE