Skip to content

Commit 7d27257

Browse files
Merge pull request #241914 from shreyaaithal/php-quickstart
Update PHP quickstart to connect to Azure MySQL Single Server
2 parents 5604dbd + ed2579c commit 7d27257

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

articles/mysql/single-server/connect-php.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ $conn = mysqli_init();
7474
mysqli_ssl_set($conn,NULL,NULL, "/var/www/html/DigiCertGlobalRootG2.crt.pem", NULL, NULL);
7575

7676
// Establish the connection
77-
mysqli_real_connect($conn, 'mydemoserver.mysql.database.azure.com', 'myadmin@mydemoserver', 'yourpassword', 'quickstartdb', 3306, NULL, MYSQLI_CLIENT_SSL);
77+
mysqli_real_connect($conn, $host, $username, $password, $db_name, 3306, NULL, MYSQLI_CLIENT_SSL);
7878

7979
//If connection failed, show the error
8080
if (mysqli_connect_errno())

0 commit comments

Comments
 (0)