Professional Documents
Culture Documents
##########################
NEW UPDATE!!!
PHPMySimpleLogin 0.3
Download full source code:
http://rapidshare.com/files/404808631/phpmysimplelogin-0.3-frozenade.co.nr.zip.html
##########################
The production of login page using PHP and MySQL is actually very simple.
I assume that you use local web server connection (Apache and PHP) and your MySQL database
configuration use localhost as hostname and root as username with blank password.
For this case, I recommend you to using XAMPP (http://www.apachefriends.org/en/xamppwindows.html).
Please download and install it to your path choice. e.g: C:\xampp
Run XAMPP Control Panel on desktop.
Lets create a database with PHPMyAdmin. Open your favorite browser, then type
http://localhost/phpmyadmin’ at your browser address bar.
Create database phpmysimplelogin.
Click Create.
Now, lets create a table, name it user with 2 (two) number of fields.
Click Go.
Click Save.
After that, we will fill the table. Click SQL menu, then type this query on textbox:
INSERT INTO user (username, password) VALUES (admin, md5(admin))
Click Go.
It means, you fill username field with string admin and username field with an encryption
string of admin.
MD5 ia a function to create one-way encryption (hashing) from our password, so it can be more
secure.
For detail, please check: http://www.php.net/manual/en/function.md5.php
Okay, now lets prepare the web pages.
Create folder phpmysimplelogin in your XAMPPs htdocs. So, it will be
C:\xampp\htdocs\phpmysimplelogin.
Remember to save all of your files you will create, inside this folder.
Run your favorite PHP code editor, e.g: PHP Expert Editor, RapidPHP, etc; or just Microsoft
Notepad is fine.
Save document below with name config.inc.
<?php
$hostname = 'localhost';
// Your
'localhost', so you're NOT necessary to
already online on the internet.
$dbname
= 'phpmysimplelogin'; // Your
$username = 'root';
// Your
$password = '';
// Your
has no password, leave it empty.