Answer Posted / nafees ahmad
Terminable middleware performs some task after the response has been sent to the browser.
This can be accomplished by creating a middleware with terminate method in the middleware.
Terminable middleware should be registered with global middleware.
The terminate method will receive two arguments $request and $response.
Example : Create TerminateMiddleware by executing the below command.
"php artisan make:middleware TerminateMiddleware".
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are the requirements to install valet?
Can you explain about serialization?
How to get requested path in laravel?
How to start, stop mysql on valet?
How does the ioc (inversion of control) container work?
List the software’s included in laravel homestead?
What is guard in laravel authentication?
How to use traits in laravel?
Explain the events in laravel?
What is laravel passport?
What is homestead.yaml?
Explain what is valet?
How can we create a record in laravel using eloquent?
What is use of print_r () and dump () functions?
What is the use of the bootstrap directory?