Start with Laravel

Introduction and requirements for laravel.

For starting the project on laravel we need 3 things to be installed in our system.

  1. Composer
    Use E:\xampp8\php\php.exeforcomposer PHP path.
  2. Node and NPM.
  3. if you are using XAMPP (e.g. E:\xampp8\php\php.exe) for composer php path : 
    For Windows, in case you’re using a locale development environment like XAMPP, just locate the php.ini file (C:\xampp\php in my case), open it and remove the semicolon from the following line.


    Restart your Apache webserver and it will work fine.

     

  4. Laravel (open command prompt :- W+R, cmd | Type composer global require “laravel/installer” and press enter).

Install and check Node & NPM first.

Let’s Start with creating the first project.

  1. Go to RUN (W+R) and type cmd.
  2. Type the path of the folder where you want to create a project, We are using xampp so we will Type ‘cd xampp/htdcos/mylaravel‘ and press Enter.
    (mylaravel is a folder which i created under htdocs).
  3. create project

    ‘example-app’ is name of project. This command will take some time and will install laravel project under ‘mylaravel’ folder with the name of ‘example-app’.

you can see folder structure under example-app like this:

 

now open url on your browser and click on ‘public‘ folder. here you can see laravel is intalled successfully.

Now the question is why we clicked on ‘public‘ folder to view our project? so, if you want to avoid ‘public’ from URL and want to run project without public in url, you have to override this from .htaccess.

How to remove public from url in laravel?

Leave a Reply

Your email address will not be published. Required fields are marked *