SAGAR MANE
SAGAR MANE

Reputation: 685

how to connect SQL server with php web application using wamp server?

i am using wamp server 2.5 and php 5.5.12 and SQL server 2014.

i am trying to connecting a php application . but its giving me an error to connecting a database

enter image description here

Upvotes: 3

Views: 25063

Answers (1)

Leandro Papasidero
Leandro Papasidero

Reputation: 3738

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

Step by Step

  1. Download SQLSRV32.EXE (Microsoft Drivers for PHP for SQL Server) from: http://www.microsoft.com/en-us/download/details.aspx?id=20098

  2. Choose path: C:\xampp\php\ext

enter image description here

  1. Uncomment or Append extension = php_sqlsrv_55_ts.dll in php.ini

  2. Restart Apache from XAMPP Control Panel (Stop/Start)

I tested it and it works 100%

Upvotes: 2

Related Questions