PHP Snippet 1:
$server = '11.22.33.44';
// Connect to MSSQL
$link = mssql_connect($server, 'db_username', 'db_password');
PHP Snippet 2:
$username ="WRITEUSER";
$password = "WRITEPASS";
$database = "WRITEDB";
$server = "WRITESERVERIP";
$connection = mssql_connect($server, $username, $password);
if (!$connection) { die('Not connected : ' . mssql_get_last_message());}
$db_selected = mssql_select_db($databaseb, $connection);
if (!$db_selected) {
die ('Can\'t use db : ' . mssql_get_last_message());
} else{
// Success
}