Access denied error while connecting to MySQL in App in Azure App Service

前端 未结 2 1880
攒了一身酷
攒了一身酷 2021-01-23 11:22

I created an Azure App Service and enabled MySql in App. I able to connect to MySql using phpMyAdmin from portal - go to app -> MySql in App -> click manage. It open another win

相关标签:
2条回答
  • 2021-01-23 11:54

    It's simple. If you have stopped the website and started it again, you must connect to the website URL from a browser, before you can use phpMyAdmin.

    0 讨论(0)
  • 2021-01-23 12:18

    Check and follow below guidelines:

    1.Locate your config.inc.php file which relates to PHPMyAdmin.

    2.Locate the line $cfg['Servers'][$i]['host'] mostly this line might have been commented out by default, if so please uncomment it.

    3.And replace that line with following:

    $cfg['Servers'][$i]['host'] = '127.0.0.1';

    4.Save it and restart the MySQL Database from your XAMPP control panel.

    5.Change your $host parameter value in the mysqli_connect() method to following:

    `$_connection = mysqli_connect(**"localhost: 3306"**, $_mysql_username, $_mysql_password, $_database);`
    

    Note: This 3306 is my MySQL port number which is its default. You should better check what's your actual MySQL Port number before going to follow these steps.

    For more details you could refer to this similar issue.

    0 讨论(0)
提交回复
热议问题