![]() |
![]() |
|
Current Projects: PHP on XP Guide — NFO Viewer — Easy Reflections — Photon Storm — HotWire — FileGlider
Thursday, May 17. 2007A Guide to running Apache 2, PHP 4 & PHP 5 on Windows XPTrackbacks
Trackback specific URI for this entry
No Trackbacks
Comments
Display comments as
(Linear | Threaded)
This is pretty close to something that I'm needing to set up, but rather than a switcher, what I need is for php 4 to run as apache mod and php 5 to run as cgi. I've been trying to get that going and haven't been successful. this is very good and maybe it will help me to work out whatever kinks i'm having...
Hi Bill. I am yet to get php 4 running as a module and php 5 as CGI, but I *have* got php 4 as CGI and php 5 as a module working perfectly. I have added a new section to the above guide (step 17) that shows you exactly how to do this. Hope it's of some use.
Yep, that's mostly what I see as far as "how tos", but unfortunately, my web host has it the other way. they've told me they would put together some notes on how they did it, but i'm still waiting. Thanks Richard...
It looks like my hosting company did post some of his notes. so if you're interested, I can send that info to you. a login is required for where it's posted...
I think this is great. My only concern is wether PHP installs files into the C:\WINDOWS or C:\WINDOWS\system32 folders when you run the PHP installer. Also, can you just unzip the PHP zip distributible without running the PHP installer distributible?
No offense (because I'm not being rude!) but if you actually read the guide you'll see that I tell you *not* to use the installer, and only to use the PHP ZIP, so you control 100% where all the files go. And I never advise to put anything into the Windows folders
Ok, thanks, I did read the whole guide but obviously missed that part. Thanks anyway.
Thanks for the great and detailed guide Richard. It was almost the same as my current setup except for the php switcher batch files. That did the trick. Also added PHP 6 for fun.
Atleast the post here doesn't turn into an OS flame war like on the list Thnx again.
Thanks for the comments
Thank you for a wonderful tutorial.
FYI: the title of step 11 the path is wrong to the host file.
Richard, this is truly the best guide to setting up php and apache i've seen online. Thank you so much
Awesome guide Richard! Thank you very much. I am new to PHP and totally self taught, so your guide saved me hours of frustration. I was able to successfully complete all the steps, through adding a second website. My next task is not so easy, because I am straying from your 'cookbook' and into the real world. I am trying to deploy a PHP 5 web application (TimeTrex) to the server. If you have any words of wisdom... I am stuck on which directory to copy all the files to. I am not sure what the "webroot directory on your web server" is, so I don't know if I am putting the files in the right place.
Hi Terry - if you followed my guide then the 'webroot' is the 'public_html' folder of the site you are trying to install to. Put the application in there and you can find it under whatever domain you created (timetrex.dev perhaps?)
Thanks Richard. I guess I did that right, (and I did name it timetrex.dev.) There must be some other reason why I am not getting expected results. Thanks to your help, I can rule out malfunctions with the PHP 5/Apache, and now I think I can rule out problems with the location of the files. I'll try some additional steps and see what can be done. The readme file for TimeTrex makes it look so simple... I very much appreciate your guide - you made it really easy. I only had one glitch - Apache errors on my first install made it not start properly. You mention the need to have port 80 available later in the guide, but it took me a couple tries to figure out that I had IIS running on port 80. When I finally thought to try stopping the IIS default website, I was back on track.
This guide is very easy to understand - well done.
However, things haven't gone as they should have... At the end of Step 7 (Install Apache) when I type in the localhost address all I get returned is a username and password request. Also, when I open the Apache Service Monitor, the little light is red. When I try "start" it says that the operation failed. Obviously, I'm no guru on these things...
My guess would be that you have another web server installed which is already running on port 80. This is why Apache can't start, and you get a password prompt (Apache would never give you a password prompt after a default install).
What other software do you have installed that could cause this? To confirm it, you could open up the httpd.conf file, find the port number and change it from 80 to 8080. Then see if Apache will start (and type in http://localhost:8080 to test)
which part of the hhtpd.conf file should I change? Would this be the Server Name? i.e. www.sandbox.dev:80
Hmmm, yes, I tried that to no effect.
The following pops up in a black box when I try to start Apache (before and after changing the line you just referred to)... <OS 10048> Only one usage of each socket address <protocol/network address/port> is normally permitted. : make_sock: could not bind to address 0.0.0.0:80 no listening sockets available, shutting down Unable to open logs
Ahh what do you have for the ServerName value?
ServerName www.sanbox.dev:80 - which is obviously mispelled - so I just corrected it.
Then, I checked the Apache Service Monitor and the light was green
OK Richard. I rebooted and found the server running as advertised. Stopped it and restarted it successfully. Logged into localhost and all going nicely as well.
So, looks like the problem is resolved. Thank you very much for your help. I'm most impressed with what you have going here. Thanks again.
Cool, thanks for putting this together. Seems to be a bit of a Linux bias in PHP tutorials out there. Glad to find this one.
Man... i don“t wanna bug you, but this is the best tutorial for setting up apache and php I ever seen. Worked perfectly, and I even got to know more than I intended to. Pretty thanks, and keep up the good work!
What an ace tutorial
I spent a day trying to get PHP/Apache/MySQL running without success. So, I uninstalled everything and followed your tutorial. Worked first time. Can't thank you enough. Like your .dev idea too.
This is the BEST TUTORIAL on the net!
You saved hips of my sleepless nights in seach of answers. Here is it all in one. Just follow the line and everythings works perfect. The other guys're right - can't thank you enough. Great Job!
Hi, i applied all the steps tp installing and config PHP5 and Apache 2. When I test it at the en with 'www.sandboc.dev' i get a page with
Index of / * index.php.txt Please help |
QuicksearchCategoriesMy AS3 Blog
Photon Storm Great PHP links
C7Y PHP Podcast CorePHP is hosted by |