Skip to content

Commit 840f035

Browse files
committed
fix connection string
1 parent 45aa0ae commit 840f035

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

articles/mysql/howto-redirection.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,11 +134,10 @@ $host = '<yourservername>.mysql.database.azure.com';
134134
$username = '<yourusername>@<yourservername>';
135135
$password = '<yourpassword>';
136136
$db_name = 'testdb';
137-
138137
echo "mysqlnd_azure.enableRedirect: ", ini_get("mysqlnd_azure.enableRedirect"), "\n";
139138
$db = mysqli_init();
140139
//The connection must be configured with SSL for redirection test
141-
$link = mysqli_real_connect ($db, 'your-hostname-with-redirection-enabled', 'user@host', 'password', "db", 3306, NULL, MYSQLI_CLIENT_SSL);
140+
$link = mysqli_real_connect ($db, $host, $username, $password, $db_name, 3306, NULL, MYSQLI_CLIENT_SSL);
142141
if (!$link) {
143142
die ('Connect error (' . mysqli_connect_errno() . '): ' . mysqli_connect_error() . "\n");
144143
}

0 commit comments

Comments
 (0)