1关掉xampp,中止xampp服务;等下。或者重启机子。php
2用xampp的shell(记住不能启动)cd c:\xampp3输入 service mysqld stop;4输入 mysqld --skip-grant-tables;5从新打开一个xamppshell(命令行)6mysql -uroot 7use mysql8 update user set password=password(111) where user='root';//重点,你之因此改了密码,但按原来的密码进不去就是由于password()把你的密码编码了。你以前是否是也和我同样updata user set password=111where user='root'9flush privileges10\q你觉得这样就ok了no还差点.11找到config.default.php更改$cfg['Servers'][$i]['password'] = '';//$cfg['Servers'][$i]['password'] = ''111;C:\xampp\phpMyAdmin\libraries\config.default.php12config.inc.php更改$cfg['Servers'][$i]['password'] = '111';$cfg['Servers'][$i]['AllowNoPassword'] = false;//C:\xampp\phpMyAdmin\config.inc.php以上是设置了默认密码,若是要启用密码$cfg['Servers'][$i]['auth_type'] = 'config';更改为$cfg['Servers'][$i]['auth_type'] = 'http'//C:\xampp\phpMyAdmin\test\test_data\config.inc.php//C:\xampp\phpMyAdmin\config.inc.php重启。ok!新版本的xammp能够参考https://www.cnblogs.com/jonsea/p/5510219.html