Oke soo如标题所说, 我在家里的Windows 7上安装了SQL Server 2005,我有一个使用linux的网站(Ubuntu 14.04,必要时可以升级),问题是
答案 0 :(得分:0)
要设置远程连接,请按照此处的说明进行操作:https://docs.microsoft.com/en-us/sql/database-engine/configure-windows/configure-the-remote-access-server-configuration-option
是的,司机是安全的。在此处开始使用说明:https://www.microsoft.com/en-us/sql-server/developer-get-started/php/windows/
示例代码
<?php
$serverName = "localhost";
$connectionOptions = array(
"Database" => "SampleDB",
"Uid" => "sa",
"PWD" => "your_password"
);
//Establishes the connection
$conn = sqlsrv_connect($serverName, $connectionOptions);
if($conn)
echo "Connected!"
?>
您可以从ipconfig