1. Run the PHP program using IIS
1. first download PHP. Here I download php5.2.14 (if it is a later version, php5isapi may not be found. dll, the related configuration method is temporarily ignored), it is recommended to download the zip package, you do not need to install it, during downloading, make sure to select the VC9 package instead of VC6 (this is for apache ). For example, I decompress to d: \ php-5.2.14-Win32.
2. FindPhp. ini-distChangePhp. iniAnd then open the file:
FindRegister_globals = Off
ChangeRegister_globals = On,
FindExtension_dir = "./"
Modify the path of the extension dll in your package. For example, if my path is d: \ php-5.2.14-Win32 \ ext, changeExtension_dir = "d: \ php-5.2.14-Win32 \ ext"
Add extension, Set
; Extension = php_curl.dll
; Extension = php_dbase.dll
; Extension = php_gd2.dll
; Extension = php_ldap.dll
; Extension = php_mysql.dll
Remove the Semicolon ";" to enable these common extensions.
3. Create a website in iis, for example, PHPTest. By default, an application pool is added to change the. NetFramework version in the application pool"Unmanaged code", Managed pipeline mode changed"Classic". Add the application ing to the website and add a script ing. The Request Path is"*. Php", The executable file is"D: \ php-5.2.14-Win32 \ php5isapi. dll"(Depending on the directory where php is located ).
Now you can run your php site. For example, create a file named"Index. php"File, add" "after running, you can see the following interface: