I have an application written in PHP that uses MySQL provided with XAMPP without any trouble. I now need to extend the application to also query a Microsoft SQL Server, so I tried using the "mssql_connect", et. al. routines, without success. The call to mssql_connect("servername", "uid", "passsword"); fails, apparently, it is trying to connect on port 4000 instead of port 1433 (as reported by wireshark). I know port 1433 is used by the database because other applications connect on 1433.
I did search the web and found freetds, which is installed (XAMPP 1.7.3a) and edited the freetds.conf file to enable the entries for SQL Server (Server 7.0, Server 2000, and Server 6.x), setting "host" to the correct host name and "port" was already 1433. Restarted XAMPP (via lampp restart), but 4000 continues to be used for the port.
Being relatively new to this technology, I suspect there might be a simple fix for this, I just have not been able to find it. I appreciate all help.