jeudi 1 février 2018

Laravel 5.5 post request error

I'm working on the project using Laravel 5.5. I have resource controller and trying to save data in store method. The route looks like this:

  Route::resource('post', 'Post\PostController');

This is Store method in the controller:

public function store(Request $request)
{
    dd($request);
}

And also I have got blade with form like this:

  <form action="/post" method="POST">
        

But I have error and don't understand what is the issue. Clicking on submit, I see this error: The page has expired due to inactivity. Please refresh and try again.

By the way, if I change form method from post to get,and also change url, it works.But using non resource controller with post method it does not work again.

Can someone tells me what's wrong here, thanks.



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire