Skip to content

Setup MVC Project

What you need

This repository should be loaded in the www folder if you are using the repository

Download the following files into the www container

Get the MVC Framework

curl -LOk && unzip && cd php-mvc-kit-master/ && find . -maxdepth 1 -exec mv {} .. \; && cd .. && rm -rf php-mvc-kit-master && rm -rf

A lot happens in the command above, so if you want to know what it does, click on the hint below.

If you want to know what happens
  • First we download the repostory that contains all the base code as a zip file
curl -LOk
  • Next we unzip the file, which gives us the php-mvc-kit-master folder
cd php-mvc-kit-master
  • Then we move all of the files into the parent folder:
`find . -maxdepth 1 -exec mv {} .. \;`

Ignore the message that says:

mv: cannot move .' to../.': Device or resource busy

  • Last we go back to the parent folder and remove the php-mvc-kit-master folder and the file

cd .. && rm -rf php-mvc-kit-master && rm -rf

Once the framework has been downloaded type in composer update and wait while some plugins are installed.

NOTE: use php composer.phar update if you are on a mac.

Setup your git repository

Setup Git

Next you will need to create your git repository so you can save your work:

git init

Add the remote repository link

// If you are using https and have a public repository (uses port 443)
git remote add origin https://url-to-your-repo

// If you are using https and have a private repository (uses port 443)
git remote add origin https://token@username:url-to-your-repo

// If you are using ssh (uses port 22)
git remote add origin

The link "https://url-to-your-repo" is the link to your github repository

Now you can go to http://localhost:8000 (docker for (your OS)) or (docker toolbox in combination with VirtualBox) and you will see the following screen:



When using Docker Toolbox for windows, the URL will be