0

I am trying to setup php 5.5.12 on my Windows server 2008 R2

I found this good tutorial that walks you step by step

http://www.youtube.com/watch?v=WUoqkPJEp4Y

After completing every step everything seems to be fine.

I created a file called phpinfo.php and put the following code into and placed it on c:/inetpub/wwwroot

<?php php_info(); ?>

But when I got localhost/phpinfo.php or http://127.0.0.1:80/phpinfo.php I get a 404 error. I do not know why it is not working. when I execute the following from commands from the command line it looks like it is working and I get many output with no error.

cd c:/php
php -i

In addition to the instruction, I added the following to the registry of windows

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\PHP]
"IniFilePath"="C:\\PHP"

Can someone tell me what else do I need to make get php up and running on windows?

This is what is using port 80 on my server enter image description here

enter image description here

Mike
  • 2,735
  • 11
  • 44
  • 68

1 Answers1

1

To use localhost or 127.0.0.1 you need apache installed on your system too.

You can download xampp or wamp they both come with PHP, MySql & Apache installed in them.

roun512
  • 149
  • 11
  • 1
    Don't forget to start the web server once it's installed. Seemingly obvious, but I've seen that question asked here before. – Nicholas Flees May 03 '14 at 01:47
  • How to install Apache by it self? I don't need MySQL as I have MySQL enterprise installed? – Mike May 03 '14 at 02:26
  • @roun512, I installed it but it failed to start. I got this error. make_sock: could not bind to address 0.0.0.0:80 I found this URL to fix it http://wiki.apache.org/httpd/CouldNotBindToAddress but I don't know hot to stop the service that is currently using port 80.. How can I determine what service is using port 80 currently and stop that service? port 80 should be used by appache. thanks – Mike May 03 '14 at 02:52
  • Port 80 is used by skype too. To determine the service that is using port 80 go to command prompt and type netstat -aon | findstr 80 It will tell you if there is any program that is using port 80 :) – roun512 May 03 '14 at 02:58
  • I don't have skype on that server. maybe IIS? I see TCP 0.0.0.0:80 0.0.0.0 LISTENING 4 (please see screenshot in the post) It does not tell me what service is using it. How would I find out that an how can I prevent it from using it? – Mike May 03 '14 at 03:08
  • Follow this : http://blogs.technet.com/b/askperf/archive/2008/08/26/what-port-is-that-service-using.aspx It will tell you what to do exactly :) – roun512 May 03 '14 at 03:11
  • @Mike, If that didn't help then download this tool from microsoft http://technet.microsoft.com/en-us/sysinternals/bb897437.aspx – roun512 May 03 '14 at 03:19
  • okay I know the owner of the service which is "System" at PID 4 But I don't know how to stop that from using it. I added another screenshot in my post above – Mike May 03 '14 at 03:20
  • @Mike, IIS is listening on port 80 too, check this out : http://stackoverflow.com/questions/1430141/port-80-is-being-used-by-system-pid-4-what-is-that – roun512 May 03 '14 at 03:26