How to return back twice in Laravel?

Viewed 17835

In Laravel, there is a function return back();, which returns the user to the previous page. Is it possible to return back(); more than once within one function to return the user back twice or several times? I tried

public function ....()
{
  return back();
  return back();
}

but it doesn't seem to work.

2 Answers

it works for me Redirect::to($request->request->get('http_referrer'))

Related