Hello.
I have a problem with mssql_connect() when connecting to SQL server over network.
My computer is inside a domain. There are two SQL servers: the first one on my PC (on localhost), the second one on a Windows Server 2008 remote computer (remote) inside the domain. Both are SQL Servers 2005.
On localhost, I have IIS7 with PHP5 running through Isapi. When I try to connect to the SQL Server on localhost with $this->Link = mssql_connect();, it works great. But $this->Link = mssql_connect('remote'); fails with "mssql_connect(): Unable to connect to server" error.
I tried everything described in the comments at http://www.php.net/manual/en/function.mssql-connect.php. Nothing seems to work, and I cannot connect to SQL Server on remote neither through Windows authentication, nor through SQL one. By the way, I can connect to remote (both with Windows authentication and SQL one) with SQL Server Management Studio.
What's the problem?
PS. On remote, both TCP/IP and Named Pipes are enabled. Disabling firewalls on localhost and remote does not solve the problem.