I have link like this with token:
<a href="?_token=">Submit New</a>
which produce url:
Now in my controller I've added condition which check one column in database and based on this is returning different views.
public function wrongIdSubmit($Id) {
$submits = self::$user->where('submit_id', $Id)->first();
if (!$txid) {
App::abort(404);
}
if($submits->submit_id > 3) {
return View::make('fail',[
'submits' => $submits
]);
}
else {
return View::make('submit',[
'submits' => $submits
]);
}
}
My question is how to pass this token ?_token=
to return View::make along with $submits variable? Because like is now I've got error
production.ERROR: Illuminate\Session\TokenMismatchException
via VLS