Middleware provides a convenient mechanism for filtering HTTP requests entering your application. For example, Laravel includes a middleware that verifies the user of your application is authenticated. If the user is not authenticated, the middleware will redirect the user to the login screen. However, if the user is authenticated, the middleware will allow the request
Month: August 2017
What is Namespaces and how it is used?
Namespaces are one of the most significant changes in PHP 5.3.Namespaces are a way of encapsulating items. As the size of your PHP code library increases, the more likely you will accidentally reuse a function or class name that has been declared before. The problem is exacerbated if you attempt to add third-party components or
What is Traits and How it is used?
Traits are one of the biggest addition in the PHP 5.4. In PHP trait is the method of code re-usability.As we know PHP is single inheritance programming language.As per my opinion, the main intention of introducing the trait in PHP is to reduce limitation of code re-usability in PHP single inheritance nature. The structure of
Execute a function before mail function fire on Contact Form 7
Contact Form 7 is one of the most popular form management plugins available on WordPress repository. Which provide user friendly interface for managing form and email body. We can also manage addition settings like success or failure message form redirection etc in plugin settings. Sometimes you will need some extra functions with POST values which