I'm using Apache/2.2.8 (Win32) PHP/5.2.6 on Windows Server 2016.
I have 2 SQL Server Instances:
1. 10.201.74.50
- Installed on the local Windows Server above.
- @@VERSION: Microsoft SQL Server 2016 (SP2-GDR) (KB4293802) - 13.0.5081.1 (X64) Jul 20 2018 22:12:40 Copyright (c) Microsoft Corporation Standard Edition (64-bit) on Windows Server 2016 Standard 10.0 (Build 14393: ) (Hypervisor)
2. 10.3.3.192\SQLEXPRESS,1433
- Installed on another Windows Server.
- @@VERSION = Microsoft SQL Server 2005 - 9.00.5000.00 (Intel X86) Dec 10 2010 10:56:29 Copyright (c) 1988-2005 Microsoft Corporation Express Edition with Advanced Services on Windows NT 6.1 (Build 7601: Service Pack 1)
I can connect to the 2 SQL Server Instances by Microsoft SQL Server Management Studio and Command Prompt as picture below.

In case of PHP code, I can connect to the first server, but can't for the second:
$link = mssql_connect("10.201.74.50","hoteldw","password");
// mssql_get_last_message(): Changed database context to 'HotelDW'.
// Work
$link = mssql_connect("10.3.3.192\SQLEXPRESS,1433","p","password");
// mssql_get_last_message():
// string(73) "mssql_connect(): Unable to connect to server: 10.3.3.192\SQLEXPRESS,1433"
$link = mssql_connect("10.3.3.192\SQLEXPRESS","p","password");
// mssql_get_last_message():
// string(68) "mssql_connect(): Unable to connect to server: 10.3.3.192\SQLEXPRESS"
$link = mssql_connect("10.3.3.192,1433","p","password");
// mssql_get_last_message():
// string(62) "mssql_connect(): Unable to connect to server: 10.3.3.192,1433"
instance nameorport no- Squirrelntwdblib.dllis on your PC and what doesmssql_get_last_message()output? - Zhorov