给phpMyAdmin修改root密码后出现访问被拒绝的问题的解决办法

在phpMyAdmin修改用户的密码其实是修改了MySQL里面用户的密码,但是phpMyAdmin这个站点本身用户的信息并没有更新。需要手动更新。

修改文件:C:\xampp\phpMyAdmin\config.inc.php,找到这一节:

/* Authentication type and info */
$cfg['Servers'][$i]['auth_type'] = 'config';
$cfg['Servers'][$i]['user'] = 'root';
$cfg['Servers'][$i]['password'] = '';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['AllowNoPassword'] = true;
$cfg['Lang'] = '';

在password那一行加上密码就行了。其他地方都不用改。

 

posted @ 2016-12-30 09:09  疯狂的键盘  阅读(2411)  评论(0编辑  收藏  举报