Laravel 4 from Beginner to Pro Part 1: Installing and Setup

Hi Guys, it’s been a while since I’ve dedicated time to creating new tutorials. So I decided it’s time to hit off with a bang.

From today you will be learning the popular Laravel 4 framework which I’m going turn in to a series of tutorials. So please do comment and let me know if you would like to learn a bit more. Your comments motivate me to write more, so keep them coming.

Let’s get started:

You need to have at least a local development environment setup to get started. I’m using xampp which you can download here.

The next thing you need to do which is an easier way of setting up your Laravel 4, is to download the Composer package manager. Composer makes your life with Laravel so much better and you will be using it to get packages installed from, just get Composer for now by downloading and installing it from here. I’m using Windows so I’ve just downloaded the installer which is a nice quick setup and you can start using it instantly.

To the command line we go:

This is the CMD window.

Now go to your start button and in the search box just type cmd your command prompt window should popup.

Now you would need to go to your xampp/htdocs directory by typing cd / then type cd C:\xampp\htdocs

Let’s create a directory called new-lw by typing mkdir new-lw in the command prompt window and then type cd new-lw.

Now you should be in the correct directory to get started. Now we need to run our Composer command “composer create-project laravel/laravel your-project-name --prefer-dist” this is an example command. Let’s try and create a new project called my-laravel-project.

Before we start we are going to make sure that composer is up to date by typing composer self-update.

Now type the following command composer create-project laravel/laravel my-laravel-project --prefer-dist

You should see the download and installation process starts for your project and once it’s done with the whole process, you can close down your CMD window if you want.

Your installation is now complete and to confirm that it’s working, all you need to do is go to your localhost url, which should look like this http://localhost/new-lw/my-laravel-project/public/

If everything went according to plan you should see the new Laravel logo with text “You have arrived”.

Congratulations you have just installed Laravel 4.

Having issues let me know? Please leave a comment and brag of your success J.

Related Posts:

  • No Related Posts
  • rss
  • email
  • rss
  • email
I'm a full time PHP developer and I just love all things web related. If you need help I'm your guy.

4 Responses to Laravel 4 from Beginner to Pro Part 1: Installing and Setup

  1. Max Sternback says:

    Good clear article, looking forward to more on this subject

  2. Morné says:

    Thanks, appreciate the kind words. Will be more coming as I get time :)

  3. John Horner says:

    Somehow –prefer-dist has changed from two dashes at the start to one long dash: –prefer-dist so copying and pasting that code did not go well.

  4. Morné says:

    Hi John,

    Thanks for letting us know. I’m fixed the issue. There was two dashes but no space. All fixed now.

Leave a Reply

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

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>