Laravel is most popular framework of PHP. It provides lots of in-build tools and library to build the web application. laravel community has working quite hard to make the laravel most efficient and secured framework for web developers that’s why most of the websites are built with laravel as backend. Laravel is used to to create robust custom web applications with ease of amazing developer experience.
Laravel add some new features in laravel and here are the nutshell
- Process Interaction
- Laravel Pennant
- Test Profiling
- Pest Scaffolding
- Generator CLI Prompts
- Horizon / Telescope Facelift
Laravel is easily customizable and provides tools like ORM, Validation libraries, Queue, Mail, Routing, Schedulers, Views engines and Model view controller architecture.
Installing Laravel using composer
To install the Laravel 10 using the composer there is few requirements which are below:
# Requirements:
- PHP 8.1+ for Laravel 10
- BCMath PHP Extension
- Ctype PHP Extension
- Fileinfo PHP extension
- JSON PHP Extension
- Mbstring PHP Extension
- OpenSSL PHP Extension
- PDO PHP Extension
- Tokenizer PHP Extension
Read how to install extensions and php and What is composer and how to install composer?.
After checking the requirements, now we can start the installation.
First step is to open the command line in windows or terminal in Ubuntu and go to the folder where you want to install the Laravel. Most probably the directory of web server (var/www/html or htdocs)
$ composer create-project laravel/laravel example-app
here, example-app
is the name of project.
This will show result as below
Getting error like below
ERROR
PHP Fatal error: Allowed memory size of 1610612736 bytes exhausted
then change composer memory limit and run composer update in example-app
COMPOSER_MEMORY_LIMIT=-1 composer update
And the directory structure after installation
then change composer memory limit and run composer update in example-app
If you are getting error Laravel 10 – Error During installation laravel/framework[v10.0.0] require composer-runtime-api ^2.2 – Solved then you can read this article
Check the installation in browser by opening URL http://domain_ip/example-app/public