samedi 19 décembre 2020

Undefined Variable Request in Laravel 5

I am having issues it says Request is undefined same goes for DB.

public function edit(Request $request,$id) {
        $name = $request->input('stud_name');
        DB::update('update student set name = ? where id = ?',[$name,$id]);
        echo "Record updated successfully.<br/>";
        echo '<a href = "/edit-records">Click Here</a> to go back.';
     }


via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire