techwrath-logo-2023

How to Create a Project in Laravel for Beginners

If u want to start a career in Web Development or just want to learn how to build your own website then u must be know about php. Php is a server-side scripting language designed for use in a web based application. As you know php is server side language,

Its require a web server installed, configured and enabled with PHP.

Actually before starting Laravel You must be know about PHP and MVC Concept then you will learn easily Laravel.

What is MVC?

The MVC is an building design that splits  an application into three main logical units:

  • Model
  • View
  • Controller

MVC is one of the most generally used industry-standard web development framework to create scalable and extensible projects.

Now we discuss about Laravel framework how to install and how to create new projects in laravel.

Some Facts about laravel

  • Laravel was developed by Taylor Otwell in July 2011 and it was released more then five years after the Codeigniter.
  • Laravel is web based framework like Codeigniter.
  • Open Source php FrameWork
  • Most popular frameWork after Codeigniter .

Laravel Features

  • Routing Controlling
  • Configuration Management
  • Testability
  • Authentication and authorization of Users
  • Modularity
  • ORM (Object Relational) Features
  • Provide Template Engine
  • Building Schemes
  • E-mailing Facilities

Installation

Before Installing the Laravel You must b Install composer In your System. Laravel utilizes Composer to manage its dependencies.

Via Laravel Installer

Download the Laravel Installer using Composer.

“composer global require laravel/installer” Once Installed, The laravel “new” command will create a fresh Laravel in directory you specify.

You can create you new Project using this Command. “Laravel new Blog”  here the Blog is Your Project name You can Change according to your requirements.

Via Composer Create Project

Using Composer to Create Project use this Command.

composer create-project –prefer-dist laravel/laravel blog

Local Development Server

If you have Installed in your system , And now you would like to use PHP’s built-in development server to serve your application.use this command.

“php artisan serve”

This Command will start a development server at https://localhost:8000.

DataBase Connection

In Laravel .env File have database connection and password you can set there user and password.

Configuration

After installing the laravel you should configure your web server’s document / web root to be the public directory. The Index.php in the directory serves as the front controller for all http requesties entering your application.

All configuration files are store in config directory. You may need some configure some permissons. Directories within the storage and the bootstrap cache directories should be writeable by your web server. If you are using the homested virtual machine then these permission already be set.

After Installation and configuration and connect the dataBase you will see this index page.

http://localhost/blog/public

Laravel provide default login system. Check this links.

http://localhost/blog/public/login

http://localhost/blog/public/register

Registration Page

This is just basic introduction about laravel. You Learned about php, MVC Concept, Laravel.

Laravel Installation, Laravel configuration, How to Make DataBase Connection, How to Create project using composer in laravel.

One Comment on How to Create a Project in Laravel for Beginners

    Alan
    March 19, 2021

    Thanks for the good writeup. It if truth be told was once a entertainment
    account it. Glance complex to more introduced agreeable from you!
    However, how can we keep up a correspondence?

    0
    0

Leave A Comment

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

The reCAPTCHA verification period has expired. Please reload the page.