How to install php-login-minimal on Windows 7 / 8
In this tutorial we’ll work through the extremely simple installation process of “php-login-minimal” (a super-simple PHP login / user authentication system) under Windows 7 (which is basically the same as in Windows 8 and 8.1). This tutorial has been created in addition to the official installation tutorial for Ubuntu 12.04 LTS as lots of people develop locally under Windows.
Some things first: PHP applications usually run on linux servers, so it’s very useful and very clean to develop on a linux server. There’s absolutly no need to develop on a real live server (security, costs, remote problems, etc.), instead virtual machines are the way to go: There’s an excellent software called Vagrant, letting you easily setup real linux servers on your local computer within seconds, servers that can exactly represent your production server. Do yourself a favour and start with Vagrant, as this will improve your PHP developer life dramatically! I’ve written some tutorials on that, here: How to setup a professional local server (in a virtual machine) with Vagrant in PHPStorm and How to setup a (or multiple) server/LAMP-stack inside a virtual machine for local development with Vagrant and PuPHPet.
If you still want to develop locally in Windows (which is totally okay, but be aware that a deployment on linux servers later might need additional work) I can recommend using one of the most advanced WAMP (Windows, Apache, MySQL, PHP) / MAMP (MAC OS X, Apache, MySQL, PHP) stacks available: EasyPHP, which will be used in this tutorial. This tool will install Apache, MySQL and PHP in a custom folder without messing up your system and provide a very clean and intuitive interface. There are others, but EasyPHP and AMPPS is my favourites. Make sure to download and install the VC9 version, the VC11 needs additional work to run properly.
The following tutorial has been made on a fresh Windows 7 installation to keep things as clean as possible.
1. Download, install and start a WAMP stack
We use EasyPHP in this tutorial. Be cool and don’t mess up your Windows 7 harddrive/partition, it’s useful to install your WAMP stack on a seperate partition. The current version comes with Apache 2.4, MySQL 5.6 and PHP 5.4 by default. Assuming that you have installed EasyPHP in D:\EasyPHP, then your web root folder is D:\EasyPHP\data\localweb ! Go there and delete the files that in in there as we don’t need them (it’s just demo stuff). Start EasyPHP. Note: There’s an EasyPHP icon in your taskbar (right, next to the clock etc, eventually the icon is hidden, then click the little white arrow to show it) that allows access to a lot of functions, configs etc. when right-clicked.
2. Download and extract php-login-minimal
Download the .zip from https://github.com/panique/php-login-minimal, extract it and move the content of the php-login-minimal-master folder into D:\EasyPHP\data\localweb, so that your index.php is directly in D:\EasyPHP\data\localweb.
3. Create and fill a demo database
Go to 127.0.0.1/home in the browser and open phpMyAdmin there. Click on “import” and import both SQL statement files from the application/_install folder.
4. Edit configs, enter database user and password
Go to 127.0.0.1/home and move your mouse over the icon next to the word MYSQL on the top. You’ll see a yellow popup showing the database login credentials. Usually it’s “root” as user and “” as the password (= no password). Edit config/db.php and change the line
Go to http://127.0.0.1 and have a look. Works perfectly.
Project’s Portal Page:
Project’s GitHub Page:
Find an much more advanced version of php-login-minimal here: