Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
phpMyAdmin is a very popular free web application that can be used to manage your MySQL databases. You can download the most recent version of phpMyAdmin from this web site, www.phpmyadmin.net. But I've included a copy of phpMyAdmin in the exercise files that come with this course, and I'll show you how to install that version. I'll go to the Free Exercise Files folder and double-click into the phpmyadmin folder.
You'll find a zip there, including phpMyAdmin 188.8.131.52. And there's also a configuration file, one for Windows and one for Mac OS X. To install phpMyAdmin, first extract the contents of the zip file. I'll extract the contents of the zip file directly to the desktop, by right-clicking and choosing Extract All and then Extract. Now you can use any zip utility you like, WinZip or anything else, because this file is in simple zip format.
Go to the extracted folder which has the same name as the zip file and double-click into it. You'll find another folder there of the same name. And then drag that folder into your document root folder. I'll open a new copy of Windows Explorer. I'll position this one over on the right and the original one over on the left. In the right window, I'll go to C:\apache\htdocs, and then I'll take this folder and drag it over to the right one. I'm done with that copy of Windows Explorer, so I'll close it.
And now for this folder, I'll rename it. I'll press F2 and call it simply phpmyadmin, all lowercase. That'll just make it easier to call from the browser. That's basically it. phpMyAdmin has been installed, but there are a couple of configurations that I recommend. Let's first test it from a browser. I'll go to my browser and I'll type in http://localhost/phpmyadmin.
Notice that I see a listing of files. This is because of a configuration that needs to be made in the Apache web server, not in PHP or in phpMyAdmin. So as I have before, I'm going to open up the httpd.conf file in a text editor. I'll go to C:\apache\conf, and I'll open the file. Now I'm going to search for the string index.html. This takes me to an option named DirectoryIndex.
By default, the Apache server is set up to default to HTML files. I want, instead, to default to PHP files, because that's the kind of file I'm primarily going to be using. So I'll change this from index.html to index.php. I'll save and close the file. I'll return to my Services control panel and restart the server. Now I'll go back to the browser and refresh.
And this time, phpMyAdmin appears, showing me a login screen. I'll type my username and my password. This is the MySQL password that you set up when you installed MySQL in a previous video. I'll click the Go button and that opens up phpMyAdmin. Now, it's also possible to configure phpMyAdmin to open automatically, using your username and password from a configuration file.
Here's how you do that. I'll close all these other windows; I'm pretty much done with those. Then I'll go to the Free Exercise Files, to the phpmyadmin folder again. I've provided a file that configures phpMyAdmin on Windows, using a minimal set of configuration options. I'll open the file in a text editor and show you that there are four options. The first three have to do with the login option. I put in the username and the password explicitly.
Again, this is the username and password for MySQL. And I've set auth_type to a value of config. You should change the password setting to your password. So if you used something else, something more secure, change it here. I've also added an option called AllowUserDropDatabase and set it to a value of true. This will make sure that you as an administrator can drop or delete databases from your MySQL database. By default, phpMyAdmin doesn't let you do that.
Now here's how I'll use this file. I'll go back to Windows Explorer, and I'll copy this file to the clipboard. Then I'll go to C:\apache\htdocs\ phpmyadmin, and I'll paste the file into place, pressing Ctrl+V. Now I need to rename the file. I'll press F2 and I'll change the file name to config.inc.php. That's all you have to do.
Now, I'll make sure that I've closed all my browser windows so that I'm logging in for the first time again. I'll open a new browser window, and once again I'll go to http://localhost/phpmyadmin. If you see the login screen initially, that's okay; press Ctrl+R to refresh the page, and this will reload the application. And this time it loads without you having to type in your username and password again. This sort of configuration is great for local development.
It is, however, not particularly secure, so I only recommend using this minimal configuration on the local development copy of this application. If you want to put phpMyAdmin on your production server, read through the phpMyAdmin documentation for their recommendations on the best settings to use. There's also a file here called config.sample.inc.php, which you can learn a lot from. It has a lot of common configurations that you can use in your own copy of phpMyAdmin.
But with this smaller configuration file that I've provided, you have everything you need to do local development and manage your local databases.
Get unlimited access to all courses for just $25/month.Become a member
82 Video lessons · 97517 Viewers
61 Video lessons · 84757 Viewers
71 Video lessons · 68937 Viewers
56 Video lessons · 101383 Viewers
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.
Your file was successfully uploaded.