XAMPP: Tips for Running an Apache/MySQL Server in Windows XP - Configuring XAMPP: Apache/PHP and MySQL in one package
(Page 2 of 4 )
Without the need for hosting space, which is quite expensive for a beginner, XAMPP offers a free solution for using Apache, PHP and MySQL. All you need to do is download the XAMP package here:
http://www.apachefriends.org/download.php?xampp-win32-1.7.0-installer.exe
If this link is broken, find it here: http://www.apachefriends.org/en/xampp-windows.html
This tutorial uses XAMPP for Windows version 1.7.0. While versions may change in the future, the functionality will be the same.
Install XAMPP in the root of your hard drive. For example, if you want to install it in drive C, it should be located at C:XAMPP and not C:FolderXAMPP.
Detailed installation procedures are out of scope of this article, but I find the installation process pretty straightforward and easy. Just be sure to close all of the running programs during the installation process.
This one-time installation will install the three most important components in a web server (Apache, PHP and MySQL). The next thing to do is check whether XAMP is running properly after installation.
To do this, open your favorite browser and type in http://localhost. You should see the XAMPP control panel. If this successful, go to http://localhost/security/index.php to put in some security measures for the following items:
1. Ensure these XAMPP pages are no longer accessible by the network for everyone.
2. Give the MySQL admin user root password protection.
3. Ensure the PhpMyAdmin password login is enabled.
You can find out how to activate these security features here: http://localhost/security/xamppsecurity.php
Make sure it shows as “Secure” in the XAMPP security page: http://localhost/security/index.php. It is very important that if you are writing PHP scripts that communicate with the MySQL database, you write down this following information for the scripts to properly retrieve or insert data from the database:
a. MySQL username
b. MySQL password
c. Hostname
The MySQL username and password can be set in the above configuration; the hostname is “localhost.”
Bear in mind that since this is running in Windows XP, Apache and MySQL are started as part of the services which can be started, stopped or paused. You can access them by going into Control panel -> Administrative Tools -> Services.
Alternatively it can be accessed also in Start -> All programs -> Apache Friends -> XAMPP -> XAMPP Control Panel. Stopping and restarting Apache is useful if you have done something to the Apache server configurations, but at this stage you should not need to; it's only necessary in case-by-case scenarios.
Stopping and restarting MySQL is useful in advanced resetting of MySQL passwords, which is difficult to do. This means you should keep a copy of your MySQL access details, and track it carefully.
Finally, this is a common mistake by beginners. Do not forget to access details to the following (after changing the security):
a. XAMPP -- XAMPP will ask you for login details the next time you access the root http://localhost, so do not forget those things you have typed in above.
b. PhpMyAdmin -- This is the control panel of MySQL, where you can easily create databases, tables, insert data, delete data and everything else, just as you need to do with spreadsheet data. If you set security settings, you will need the MySQL username and password to log into PhpMyAdmin
Finally, all configurations can be found here: http://localhost/xampp/ , as this is the control panel for XAMPP.
Next: Useful XAMPP Techniques >>
More BrainDump Articles
More By Codex-M