Yesterday, I showed you how to install MySQL Server 5.1 (Community Edition) onto your Windows-based development machine. The reason I wrote the article was to help you prep your machine for installing PHP and PHP-based applications using Microsoft’s Web Platform Installer.
Web Platform Installer is, as the website puts it, “a free tool that makes it simple to download, install and keep up-to-date with the latest components of the Microsoft Web Platform”. Yes, this is stuff you can do yourself, but I’m all for tools that automate away drudgery.
As of this writing, there are two versions of Web Platform Installer available: the original 1.0 version and the beta 2.0 version. In this article, I’m going to focus on the 2.0 version.
Here’s what you’ll see when you fire up the Web Platform Installer 2.0 beta:
Web Platform Installer has three tabs:
If PHP isn’t on your system, it will appear on the What’s New? tab page. If you click on the “information” icon beside the checkbox item for PHP, you’ll be shown its information page:
You can choose to install PHP by checking PHP’s checkbox in the list of applications or the Click to include in your install button.
You can choose to add other applications to your install. Once you’ve chosen all the apps you want, click the Install button. You’ll be presented with a list of the apps you chose for review, along with any dependencies for those apps:
To start the installation, click the I Accept button, and Web Platform Installer will do its thing:
Let’s write a very quick script to confirm that PHP is up and running:
In case you’re not familiar with PHP’s built-in phpinfo() function, it returns information about your PHP installation, its configuration and its current environment. It’s useful for all sorts of things, not the least of which is checking to see if your PHP installation worked.
Enter the script above using your favourite editor, and save it as test.php into the web root directory, c:/inetpub/wwwroot Note that in order to save to this directory, you’ll need to be running the editor with administrator privileges. Alternately, you can save to another directory and then copy the file to c:/inetpub/wwwroot, giving your administrative approval when prompted by the dialog box.
Then point your browser at http://localhost/test.php -- you should see something that looks like this:
With PHP up and running, you can install PHP-based apps. PHP apps are like old-school ASP apps; installing them is often a matter of moving the files into the webroot directory and perhaps running an install script by typing its URL into your browser.
One app you might want to consider installing is phpMyAdmin, a PHP-based web application for administering MySQL databases. While it’s possible to administer MySQL solely through its command-line interfaces, phpMyAdmin makes it so much easier. I can’t recommend this utility enough.
If I had to recommend just one PHP book, it would be No Starch Press’ Wicked Cool PHP. I find No Starch books to be both informative and enjoyable reads, and this book is no exception. If you’ve got at least a little programming experience under your belt. I think that you’ll find this book and its very useful examples, coupled with the online documentation at PHP.net, will serve you very well.
PingBack from http://www.globalnerdy.com/2009/05/05/installing-php-on-windows-using-the-web-platform-installer-20-beta/
helpful and easy to understand.
This week, I’m going to have my hands full on Friday with WordCamp Toronto , so I’m moving my Coffee
It's really nice and helpful, however, you still have to do Application Mapping on IIS manually:
.php "C:\Program Files\PHP\php-cgi.exe"
I have PHP Version 5.2.1 installed on my Win XP Pro box. I have MySQL Server 5 installed. I have a session variables working fine. I have a couple of PHP web apps running on the box just fine.
But I cannot instal phpMyAdmin. There seems to be no straightforward instal; you have to tweak so many stupid values by hand; and the end result for me, when I try to view the app at http://localhost/phpmyadmin, is the following output:-
phpMyAdmin - Error
Cannot start session without errors, please check errors given in your PHP and/or webserver log file and configure your PHP installation properly.
I can find nothing of any use in any logs. It's a dead end for someone like me who is not an expert at how phpMyAdmin is trying to work. There is no clue pointing me where to look for the answer. It would be great if phpMyAdmin could be added to the Web Apps Gallery, because a hand-instal is brutal.