Interview Question in Sql Server 2000


 

Interview Question :: How to connect PHP with Sql Server 2000

Thats pretty straighforward..
Connect to the server using mssql_connect ( servername, username, password)
However, read this note from php manual:
______________________________________...
If you use PHP on Windows with Apache as a web server, you may get problems with authentication to MS SQL Server even when you supply all valid credentials.
Check your php.ini file:
; Use NT authentication when connecting to the server
mssql.secure_connection = On
If you have secure_connection = On, make sure that you provide valid credentials in the properties for Apache service in the System Services box. Then you should not send DB username and password from your script to MSSQL Server.
If you want to use specific credentials from a PHP script, then set mssql.secure_connection = Off in your php.ini
____________________________________

If you explicitly state the problem you are facing (error messages), people can help you better.
by ksk