-1

it gives Error

An uncaught Exception was encountered Type: Error

Message: Call to undefined function sqlsrv_connect()

Filename:/home2/avyat/public_html/doitcenter_test/system/database/drivers/sqlsrv/sqlsrv_driver.php

Bhargav Chudasama
  • 6,928
  • 5
  • 21
  • 39
priya
  • 9
  • 3

3 Answers3

0

The MSSQL extension is not available anymore on Windows with PHP 5.3 or later. SQLSRV, an alternative driver for MS SQL is available from Microsoft: ยป http://www.microsoft.com/en-us/download/details.aspx?id=20098

reference from : see here to step by step how to resolve issue

Bhargav Chudasama
  • 6,928
  • 5
  • 21
  • 39
  • So what you are basically saying is this is a Dup otherwise this is just plagiarism of the answer you quote in your answer โ€“ RiggsFolly Sep 06 '18 at 09:37
0

First, check that the extension is properly loaded in phpinfo(); (something like sqlsrv should appear). If not, the extension isn't properly loaded. You also need to restart apache after installing an extension.

Common glitches include:

  1. Edit the wrong php.ini file (that's typical with bundles); the right a path is shown in phpinfo()
  2. Forget to restart Apache
  3. Not be able to see the startup errors; those should show up in Apache logs, but you can also use the command line to diagnose it, e.g.:

    php -d display_startup_errors=1 -d error_reporting=-1 -d display_errors -c "C:\Path\To\php.ini" -m

Bhavin Solanki
  • 1,364
  • 11
  • 27
0

You have add the SQLSRV php_sqlsrv_55_ts.dll drivers.

Add to the php.ini file

extension=php_sqlsrv_55_ts.dll

or

extension=php_sqlsrv_55_nts.dll
Sunny Kalariya
  • 336
  • 2
  • 9