Fatal error: calling undefined function mssql_connect () in php

I am running Windows Server, MS Sql and IIS6. I am trying to connect php to sql sql database and I keep getting the following error from script

Fatal error: call to undefined function mssql_connect () on line .... on line x

I have installed zend studio in the directory C:\Program Files\Zend\ZendStudio-5.5.0 . Configure the IIS server and set the path variable to ;C:\Program Files\Zend\ZendStudio-5.5.0\bin\php5 . The zend studio folder contains php4 and php5 in the bin directory. I added extension=php_mssql.dll to the php.ini , which is located inside the C:\Program Files\Zend\ZendStudio-5.5.0\bin\php5 . And added php_mssql.dll to ext dir. The php.ini also placed in the path to the C:\WINDOWS window.

+2
source share
2 answers

For the changes made to php.ini to take effect, you must stop and start the IIS web service.

In addition, mssql requires: ntwdblib.dll to access the Windows PATH. It is better to add the php folder in Windows PATH instead of moving any files. Restart the computer or restart the computer to make changes to the Windows PATH instruction.

0
source

mssql_ * APIs are no longer available in the latest version of PHP. This extension is no longer available on Windows with PHP 5.3 or later.

You may need to fix and compile yourself because it is not included in the open source package.

0
source

Source: https://habr.com/ru/post/908289/


All Articles