Tôi nhận được hai lỗi khi tôi cố gắng đi đến localhost phpmyadmin tôixampp localhost phpmyadmin Truy cập bị từ chối cho người dùng 'root' @ 'localhost' (sử dụng mật khẩu: YES)
Access denied for user 'root'@'localhost' (using password: YES)
phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in your configuration and make sure that they correspond to the information given by the administrator of the MySQL server.
Tôi không biết những gì Tôi đang làm sai ... đây là mã cấu hình của tôi ...
$cfg['blowfish_secret'] = ''; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */
/*
* Servers configuration
*/
$i = 0;
/*
* First server
*/
$i++;
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'config';
/* Server parameters */
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = 'password';
$cfg['Servers'][$i]['connect_type'] = 'socket';
$cfg['Servers'][$i]['compress'] = false;
$cfg['Servers'][$i]['AllowNoPassword'] = false;
/* Select mysqli if your server has it */
$cfg['Servers'][$i]['extension'] = 'mysql';
/* User for advanced features */
//$cfg['Servers'][$i]['controluser'] = 'pmauser';
//$cfg['Servers'][$i]['controlpass'] = 'pmapass';
/* Advanced phpMyAdmin features */
//$cfg['Servers'][$i]['pmadb'] = 'phpmyadmin';
//$cfg['Servers'][$i]['bookmarktable'] = 'pma_bookmark';
//$cfg['Servers'][$i]['relation'] = 'pma_relation';
//$cfg['Servers'][$i]['table_info'] = 'pma_table_info';
//$cfg['Servers'][$i]['table_coords'] = 'pma_table_coords';
//$cfg['Servers'][$i]['pdf_pages'] = 'pma_pdf_pages';
//$cfg['Servers'][$i]['column_info'] = 'pma_column_info';
//$cfg['Servers'][$i]['history'] = 'pma_history';
/*
* End of servers configuration
*/
/*
* Directories for saving/loading files from server
*/
$cfg['UploadDir'] = '';
$cfg['SaveDir'] = '';
?>
Tôi nhận thấy rất nhiều mã được nhận xét, tôi có nên bỏ nhận xét không?
bạn có chắc chắn rằng bạn cần mật khẩu để kết nối với cơ sở dữ liệu của bạn không ?? nếu bạn không cần mật khẩu, hãy làm điều này $ cfg ['Servers'] [$ i] ['password'] = ''; –
lỗi này xảy ra khi kết nối với cơ sở dữ liệu. Vì vậy, hãy thử để echo các chi tiết chuỗi kết nối để gỡ lỗi (để biết những gì giá trị của nó tham gia để kết nối là các giá trị chính xác hay không). – deepi
Bạn đã truy cập trang xampp mặc định và đi qua các màn hình bảo mật chưa? – shapeshifter