How To Install Laravel
Before Start Installing Laravel Let's first Know What is Laravel. i Know Some PHP Developers know about What is Laravel . But For rest Laravel is a PHP frameworks which Maker our Easy By Using OOP Concept of MVC (Model+view+controller).
Model = Our Data Provider (E.g Database .)
View = Our HTML Page
Controller = Our Login and Functions.
Routes:
All the Request in laravel whether its GET or POST must be passed through a file (web.php or routes.php) this files handles routing means where we send the user in POST or GET Request.
Let's Start Installing (Currently i am Using Ubuntu).
Step 1: Install PHP (if Already installed Skip it)
Code : sudo apt-get install php
Step 2 : Install PDO Extension (If already Installed Skip it)
Code : sudo apt-get install php-mysql
Step 3 : Install PHP Mbstring (if already install Skip it)
Code : sudo apt-get install php-mbstring
Step 4 : Install PHP xml (if already install Skip it)
Code : sudo apt-get install php-xml
Step 5 : Install PHP zip (if already install Skip it)
Code : sudo apt-get install php-zip
Step 6 : Install PHP Composer (if already install Skip it)
Code :
curl -sS https://getcomposer.org/installer | sudo php -- --install- dir=/usr/local/bin --filename=composer
Step 7 : Install Laravel (if permssion problem try with sudo)
Code : composer global require "laravel/installer"
Step 8 : Create Laravel Project
Step 8 : Create Laravel Project
Code : composer create-project --prefer-dist laravel/laravel blog "5.3.*"
Now Open blog folder
cd blog
Run: -
command : php artisan serve
Now Local Development Server is Ready open the given url in console.
Laravel Run at Default port is 3000 but if your 3000 port is already using some application .
Change the port when running
Command : php artisan serve --port=3001
No comments:
Post a Comment