How to reset the request object in laravel
大家讲道理
大家讲道理 2017-05-16 16:50:10
0
2
322

Reset or destroy
In an ajax request, calling another method is always affected by the current request

As shown above, these parameters should be removed in the next method

大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(2)
PHPzhong

Your $request 是从服务容器里取出来的吧?那你可以直接使用 ContainerforgetInstancesetInstance 方法来重新绑定 Request instance to the container, please refer to: Laravel API

for details

As for how to create the Request 对象,可以使用 IlluminateHttpRequest::capture() method.

伊谢尔伦

Can you be more specific about the question? It would be better if you put some code.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template