Start learning with our library of video tutorials taught by experts. Get started
Viewed by members. in countries. members currently watching.
Installing Apache, MySQL, and PHP with David Gassner describes how to install and configure Apache HTTP server, MySQL database server, and PHP, known as the AMP stack, on a local development computer. Chapters are devoted to multiple installation approaches: installing the components separately on both Windows and Mac (including coverage of Apache and PHP on Mac OS X 10.7 Lion and 10.8 Mountain Lion), installing the pre-packaged Apache and MySQL distributions in WampServer on Windows and MAMP on Mac, and installing the cross-platform XAMPP and Bitnami on both Mac and Windows. Exercise files are included with the course.
This course was updated on 07/06/2012.
The software bundle spelled X-A-M-P- P is pronounced either ZAMPP or XAMPP depending on who is talking. You can download XAMPP for free from www.apachefriends.org/en/xampp.html. There are versions available for Linux, Windows, Mac OS X, and Solaris, and XAMPP is completely free and does not require any registration. To use XAMPP for Windows, click on the XAMPP for Windows link and then download the software, using this link under Download.
Unlike WampServer, another software bundle for Windows which includes both a 32-bit and a 64-bit distribution, XAMPP is only available in a 32-bit installation, but that's okay. It should work fine on any edition of Windows XP, Windows Vista, or Windows 7. I've downloaded the XAMPP installer to my desktop, and I will start it by double-clicking. If I am prompted with a User Account Control dialog, I will click Yes. I will choose my language, English, read through any informational notes that pop up, and then continue through the prompts.
Here I am asked where I want to install XAMPP. The default is c:\xampp. You can choose any other folder, but I strongly recommend choosing a folder name without any spaces. I will use the default and click Next. On this screen, I accept all of the defaults, including creating a desktop icon to easily start XAMPP up and creating a folder in the Start menu. I am not going to install Apache, MySQL, or FileZilla, which is in the FTP server, as services.
Instead, I am going to want to run them as applications, so I will just leave those check boxes unselected and I will click Install. The extraction and copying of the files over to your hard disk will take a few minutes. You're getting copies of the Apache HTTP server, the MySQL database server, the FileZilla FTP server, phpMyAdmin-- that's a web application for managing your MySQL databases--and many other components which you might be interested in.
For example, WampServer also includes an entire PERL development environment, which is something you'd otherwise have to install separately on Windows. When you get to this screen, you're finished installing XAMPP. Click Finish and then to start up the XAMPP control panel, click Yes. If you see this dialog box, don't panic; everything is still okay. Click OK and that will open up the control panel application.
You'll see that there are start buttons associated with each of the major applications we'll be using: Apache and MySQL. To start up Apache, click the Start button and then once it shows that it's running, click Admin. That should open up your browser and show this page that says "It works!" This is the very simple Apache homepage that's included with your XAMPP installation. Now, I will show you where that file is located. I will click the Explore button, and that opens up Windows Explorer to the XAMPP homepage and from there, I will double-click into the htdocs.
This is the document root directory for your copy of Apache. This index.html file is the file that you saw on the screen. Now, I will go back to the XAMPP control panel, and I will start MySQL. You should see MySQL fire up very quickly. If you try to click the Admin button, in this version of XAMPP you will see that it doesn't do anything. That is, to put it bluntly, a bug. Here is the workaround. What you're trying to do is to get into the phpMyAdmin application, and you can get to it through the browser if you know the steps.
Click the Admin button for Apache, instead of the button for MySQL, go to the URL, localhost, and append simply XAMPP to it. When you press Enter, that will change the URL and display a splash screen. And from there, click on English, or whatever language you want to read the page in, and that will take you to the homepage for the XAMPP installation. In some other videos in this chapter, I will show you some other tools that you can get to through this page, so you might want to bookmark, or set this page as a favorite.
But here's the thing I wanted to show you. From this page, you can click on phpinfo. That will show you which version of PHP you're currently using. But most importantly, you can get to the phpMyAdmin web tool for managing your databases. Go down to Tools and click on phpMyAdmin. If this screen opens correctly, it means that both Apache and MySQL are operating correctly, and you're ready to start creating your own databases and managing your data through this web interface.
XAMPP is installed by default with minimal security. It's designed to be used for local development only, and not as a production server. But there are certain security considerations you want to pay attention to, and I will show you how to deal with those security considerations in another video.
Find answers to the most frequently asked questions about Installing Apache, MySQL, and PHP.
Here are the FAQs that matched your search "":
Sorry, there are no matches for your search ""—to search again, type in another word or phrase and click search.
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.