PHPnews.io

Overview for 'laracasts'

Abstract Classes

Written by Laracasts / Original link on Dec. 10, 2019

An abstract class provides a template - or base - for any subclasses. In this lesson, we'll work through an example that demonstrates how, why, and when you might reach for an abstract class.


Laravel Facades Demystified

Written by Laracasts / Original link on Dec. 5, 2019

Now that you have a basic understanding of the service container, we can finally move on to Laravel facades, which provide a convenient static interface to all of the framework's underlying components. In this lesson, we'll review the basic structure, how to track down the underlying class, and whe…


Inheritance

Written by Laracasts / Original link on Dec. 4, 2019

Inheritance allows one class to inherit the traits and behavior of another class. This should instantly make sense, in the same way that a child inherits characteristics from their parents. In this lesson, we'll review several examples of inheritance in action.


Automatically Resolve Dependencies

Written by Laracasts / Original link on Dec. 3, 2019

Now that you understand the basics of a service container, let's switch over to Laravel's implementation. As you'll see, in addition to the basics, it can also, in some cases, automatically construct objects for you. This means you can "ask" for what you need, and Laravel will do its best - using …


Service Container Fundamentals

Written by Laracasts / Original link on Dec. 1, 2019

Laravel's service container is one of the core pillars of the entire framework. Before we review the real implementation, let's first take a few moments to build a simple service container from scratch. This will give you an instant understanding of what happens under the hood when you bind and res…


CSRF Attacks, With Examples

Written by Laracasts / Original link on Nov. 26, 2019

Laravel provides Cross-Site Request Forgery (CSRF) protection out of the box, but you still may not know exactly what that means. In this lesson, I'll show you a few examples of how a CSRF attack is executed, as well as how Laravel protects your application against them.