6

I am trying to install PHP 5 on a Windows Server 2003 environment with IIS 6

After installing PHP, and making the necessary changes in IIS, I get the following error

%1 is not a valid Win32 application.
  • The server is not 64bit, it is 32bit. I have added the FastCGI handler in Web Service Extensions,
  • I have added the PHP handler in
  • Web Service Extensions, I have also gone to "Web Sites Properties" and clicked on Configuration: and set the appropriate mappings,
  • I've installed the reditrubition files as required by Microsoft...

I cannot for the life of me work out why it is not working.

Can someone please help?!

6 Answers6

8

Finally got my installation working by installing the correct corresponding versions and dependencies. I hope this helps.

On IIS 6

On IIS 7

bubbassauro
  • 3,969
  • 2
  • 45
  • 45
3

Try running PHP directly from command line to see if you receive the same error. If it is, the issue may be that a dependency cannot be found. PHP has a dependency on the Visual C++ Redistributable - from http://windows.php.net/download/ :

  • The VC9 builds require you to have the Visual C++ Redistributable for Visual Studio 2008 SP1 x86 or x64 installed.
  • The VC11 builds require to have the Visual C++ Redistributable for Visual Studio 2012 x86 or x64 installed.

if this doesn't help, run the Microsoft utility Depends.exe from http://www.dependencywalker.com/ to find out what might be the issue.

InActive
  • 822
  • 6
  • 5
0

in System Properties > Environment Variables click on new in variable name = path and variable value = C:\wamp\bin\php\php5.3.13; and click on ok > ok > ok click on run type cmd in cmd type php if you get up error in cmd type cd c:\ and enter now type php

0

I have faced the same issue on standalone Apache+PHP setup on Windows 10. Definitely the problem was in two different PHPs in the environment variable PATH (IIS distro and standalone distro). Removing the PHP for IIS from the PATH resolved the problem.

jspetrak
  • 103
  • 1
  • 9
0

Unfortunately PHP only goes as far as 5.4 on Windows 2003. They officially dropped support for Windows XP and 2003 starting PHP 5.5.0.

http://windows.php.net

Rio Bautista
  • 433
  • 5
  • 4
0

Here you can find PHP for older Windows systems: PHP 5.5.7, 5.4.23, 5.3.28 (x86/x64) available

Following binaries are available:

  • php-5.5.7-nts-Win32-VC11-x86.zip
  • php-5.5.7-Win32-VC11-x86.zip
  • php-5.5.7-nts-Win32-VC11-x64.zip
  • php-5.5.7-Win32-VC11-x64.zip
  • php-5.4.23-nts-Win32-VC9-x86.zip
  • php-5.4.23-Win32-VC9-x86.zip
  • php-5.4.23-nts-Win32-VC9-x64.zip
  • php-5.4.23-Win32-VC9-x64.zip
  • php-5.3.28-nts-Win32-VC9-x86.zip
  • php-5.3.28-Win32-VC9-x86.zip
  • php-5.3.28-nts-Win32-VC9-x64.zip
  • php-5.3.28-Win32-VC9-x64.zip

For "FastCGI" on Windows Server 2003, you should choose php-5.4.23-nts-Win32-VC9-x86.zip.

deblocker
  • 7,629
  • 2
  • 24
  • 59