I can not view any php documents on my server scince i upgraded from xp to server 2003 standard edition. i get a http 404 error. can anybody help?
Printable View
I can not view any php documents on my server scince i upgraded from xp to server 2003 standard edition. i get a http 404 error. can anybody help?
For security, in Server 2003 you have an application pool. It is basically a list of extensions and the associated programs, if any which should be invoked when a file with that extension is added. Any extension which is not present, will result in a 404 error on the client side.
Are you using PHP as an IIS module or as a CGI script and which version of PHP are you running?
I am using php version 5.0.4. I think that is the right way round and how do i tell wether it is CGI or Module?
Do you run it through the sapi DLL or through the php-cgi executable?
i have no idea but the server 2003 os has realy messed up and i have to spend all night reinstalling windows xp on the thing. sorry :( .
For the PHP CGI you need to do the following:
- Open up the Application Server Control Panel and find your web server.
- Right Click on your web server and select Properties
- Click on the Home Directory Tab
- Find the frame which says Application Settings and click on Configuration
- You should now see a list of extensions, which include asp, shtml etc.
- Click Add
- Assuming your PHP CGI is in C:\php-5, enter the following in the executable box. "C:\php-5\php-cgi.exe", ensure that, this is where the CGI is (you may need to copy it form one of the sub directories)
- In the extension box, type PHP
- Now Click OK, all the way back through to the Application Server control panel.
- Finally, you need to add PHP to the allowed Web Service Extensions list. You can find this under your websites in an appropriately named tree.
- Click on Add New Web Service Extension in the Tasks pane on the left.
- Enter the extension name as PHP 5 and in the allowed files box add the PHP CGI.
- Click the check box underneath to set the status to allowed and click OK.
You are done, happy PHP'ing :)
Server 2003 is a different kettle of fish. Security is put way above usability - I doubt it is messed up, it just needs to be configured. :)Quote:
Originally Posted by dandono
i will try installing the os again some time but at the moment i am happy enough with windows xp. i only wanted server sk3 installed because i can make online radio station in it and the network logon. thanks anyway.
ok i have finaly reinstalled server 2k3 and i am doing it in a rush because i need to wake up at like 7 tomorow for school (boring). Thank you :D My server is now running svr 2k3 and i can do a lot more with my website :D Thanks. I just need to test out the actual server incase i need to find out how to fix some other problem to do with the iis user but it has only happened once and i think a good old reboot fixed it any how Thanks!
I have just reinstalled server 2003 again because of a completly different problem but i did exaclty as you said but this time it gives me this only on php scripts:
"CGI Error
The specified CGI application misbehaved by not returning a complete set of HTTP headers."
how can i fix this?
thanks, dandono.
You need to turn force CGI redirect off in php.ini for IIS:
Code:cgi.force_redirect=0
ive lost php.ini. it's suppose to be in C:\windows\php.ini isnt it
never mind. i copied php.ini to C:\windows and it works. thanks for the several replys adam.