reference/sqlsrv/functions/sqlsrv-connect.xml
4754397753fd79f1c846868b66a2448babab1c54
...
...
@@ -28,7 +28,7 @@
28
28
<listitem>
29
29
<para>
30
30
The name of the server to which a connection is established. To connect
31
-
to a specific instance, follow the server name with a forward slash
31
+
to a specific instance, follow the server name with a backward slash
32
32
and the instance name (e.g. serverName\sqlexpress).
33
33
</para>
34
34
</listitem>
...
...
@@ -63,7 +63,7 @@
63
63
<programlisting role="php">
64
64
<![CDATA[
65
65
<?php
66
-
$serverName = "serverName\sqlexpress"; //serverName\instanceName
66
+
$serverName = "serverName\\sqlexpress"; //serverName\instanceName
67
67

68
68
// Since UID and PWD are not specified in the $connectionInfo array,
69
69
// The connection will be attempted using Windows Authentication.
...
...
@@ -87,7 +87,7 @@ if( $conn ) {
87
87
<programlisting role="php">
88
88
<![CDATA[
89
89
<?php
90
-
$serverName = "serverName\sqlexpress"; //serverName\instanceName
90
+
$serverName = "serverName\\sqlexpress"; //serverName\instanceName
91
91
$connectionInfo = array( "Database"=>"dbName", "UID"=>"userName", "PWD"=>"password");
92
92
$conn = sqlsrv_connect( $serverName, $connectionInfo);
93
93

...
...
@@ -104,11 +104,11 @@ if( $conn ) {
104
104
</para>
105
105
<para>
106
106
<example>
107
-
<title>Connect on a specifed port.</title>
107
+
<title>Connect on a specified port.</title>
108
108
<programlisting role="php">
109
109
<![CDATA[
110
110
<?php
111
-
$serverName = "serverName\sqlexpress, 1542"; //serverName\instanceName, portNumber (default is 1433)
111
+
$serverName = "serverName\\sqlexpress, 1542"; //serverName\instanceName, portNumber (default is 1433)
112
112
$connectionInfo = array( "Database"=>"dbName", "UID"=>"userName", "PWD"=>"password");
113
113
$conn = sqlsrv_connect( $serverName, $connectionInfo);
114
114

115
115