Help with mssql_connect and Windows Server 2003

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
spideybum
Forum Newbie
Posts: 2
Joined: Tue May 02, 2006 7:25 am

Help with mssql_connect and Windows Server 2003

Post by spideybum »

Someone please help me out. I am trying to connect from a PHP file on a Windows Server 2000 machine to an SQL database on a Windows Server 2003 machine. I keep getting a

mssql_connect(): Unable to connect to server: <servername> in <phpfilename> on line <linenumber>

error. The SQL has been recently moved to the 2003 server from a 2000 server, and from what I've read elsewhere, that is the issue. I have searched a few sites that had supposed workarounds. I replaced the ntwdblib.dll file on the server that has PHP with a newer one (and restarted the server), but that didn't make a difference. What can I do?

Doug Applegate
User avatar
neophyte
DevNet Resident
Posts: 1537
Joined: Tue Jan 20, 2004 4:58 pm
Location: Minnesota

Post by neophyte »

Is the firewall open on the right port?
spideybum
Forum Newbie
Posts: 2
Joined: Tue May 02, 2006 7:25 am

Post by spideybum »

We don't go through a firewall from internal computer to internal computer.
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

Post by Burrito »

can you connect to the sql server from the web server via a different method (other than php)?

you might try that to ensure that the new sql server isn't blocking access based on IP or some such....
Post Reply