I've been having some trouble connecting to a MS SQL server through PHP. Since PHP doesn't have the MSSQL functions by default, I think I went through all of the proper steps to add them. However, I am still having trouble connecting.
Here's my code:
Now here is what I get:
$hostname = '10.89.192.23';
$username = "xxx";
$password = "xxx";
//echo "Error connecting to MS SQL Server";
[b][size=1]Warning: mssql_connect() [[/size][/b][url=http://www.php.net/function.mssql-connect][size=1][color=#0000ff][b]function.mssql-connect[/b][/color][/size][/url][b][size=1]]: Unable to connect to server: 10.89.192.23 in D:\WEB\test\index.php on line 7[/size][/b]
Even if the username/password is wrong, it still shouldn't say "unable to connect to the server," right? I am positive that is the right address of the SQL Server and I know it uses the default port. Can anybody think of what I am doing wrong?
Also, I am failry sure the SQL server is setup correctly. People are able to remotly connect to it (through that IP) using methods other than PHP.
Thanks for your help!