app/Http/Controllers/SettingController.php
/**
     * Update the specified resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @param  int  $id
     * @return \Illuminate\Http\Response
     */
Update the specified resource in storage.
Update the specified resource in storage .
public function update(Request $request, $id)
    {
        $request->validate([
            'phone' => 'required',
            'email' => 'required',
            'about_app' => 'required',
            'fb_link' => 'required',
            'tw_link' => 'required',
            'inst_link' => 'required'
        ]);
        $setting= Setting::find($id);
        $setting->update($request->all());
        return redirect(route('setting.index'));
    }
public function update ( Request $ request , $ id ) { $ request -> validate ( [ 'phone' => 'required' , 'email' => 'required' , 'about_app' => 'required' , 'fb_link' => 'required' , 'tw_link' => 'required' , 'inst_link' => 'required' ] ) ; $ setting = Setting :: find ( $ id ) ; $ setting -> update ( $ request -> all ( ) ) ; return redirect ( route ( 'setting.index' ) ) ; }
Update the specified resource in storage.
Update the specified resource in storage .
//validation //store