How to create Facade in Laravel ?



How to create Facade in Laravel ?..

Answer / suresh kumar

The following are the steps to create Facade in Laravel -

Step 1 - Create PHP Class File.

Step 2 - Bind that class to Service Provider.

Step 3 - Register that ServiceProvider to

Configapp.php as providers.

Step 4 - Create Class which is this class extends to

lluminateSupportFacadesFacade.

Step 5 - Register point 4 to Configapp.php as aliases.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Laravel PHP Framework Interview Questions

Tell me what are the feature of laravel 5.0?

0 Answers  


How will you explain guarded attribute in a laravel model?

0 Answers  


What do you mean by laravel mix?

0 Answers  


Explain auth.

0 Answers  


Does laravel prevent sql injection?

0 Answers  


What is chunk in laravel?

0 Answers  


What is url in laravel?

0 Answers  


What is luman?

0 Answers  


How to create view Laravel - File Uploading ?

1 Answers  


Explain the bindings and singletons properties?

0 Answers  


What are pros and cons of using laravel framework?

0 Answers  


What is current stable version of laravel?

0 Answers  


Categories