The MSSQL extension php_mssql.dll that comes with PHP is for SQL Server 2000. Can’t connect to 2008? ! -_-!! To use SQL Server 2005 or above, you must use the latest third-party extension SQL Server Driver for PHP provided by Microsoft.
You can download it from here: Click to open the link
Download the driver, and install the release program after downloading. There are the following files in it:
php_pdo_sqlsrv_52_nts.dll
php_pdo_sqlsrv_52_ts.dll
php_pdo_sqlsrv_53_nts_vc6.dll
php_pdo_ sqlsrv_53_nts_vc9.dll
php_pdo_sqlsrv_53_ts_vc6.dll
php_pdo_sqlsrv_53_ts_vc9. dll
php_sqlsrv_52_nts.dll
php_sqlsrv_52_ts.dll
php_sqlsrv_53_nts_vc6.dll
php_sqlsrv_53_nts_vc9.dll
php_sqlsrv_53_ts_vc6.dll
php_s qlsrv_53_ts_vc9.dll
SQLServerDriverForPHP.chm (manual, if your English is good enough, you can read it, hehe)
SQLServerDriverForPHP_License.rtf
SQLServerDriverForPHP_Readme. htm (readme file)
About the difference between VC6 and VC9
The VC6 version is compiled using the Visual Studio 6 compiler. If you are using Apache+PHP under Windows, please choose the VC6 version.
The VC9 version is compiled using the Visual Studio 2008 compiler. If you are using IIS+PHP under Windows, please choose the VC9 version.
Start configuration
Select php_sqlsrv_53_ts_vc6.dll and php_pdo_sqlsrv_53_ts_vc6.dll. Copy the file to the ext directory in the PHP folder, and then add:
extension=php_sqlsrv_53_ts_vc6.dll
extension=php_pdo_sqlsrv_53_ts_vc6.dll