2013-07-02 89 views
1

我一直在尋找解決這個問題的方法,但是無法獲得任何地方。WampServer - 拒絕用戶'root'@'localhost'的訪問

所以我已經安裝了WampServer並重新安裝了好幾次,現在,當我嘗試加載localhost/phpmyadmin我得到這個錯誤:

#1045 - Access denied for user 'root'@'localhost' (using password: YES)

這也是我config.inc.php文件:

/* Server: localhost [1] */ 
$i++; 
$cfg['Servers'][$i]['verbose'] = 'localhost'; 
$cfg['Servers'][$i]['host'] = 'localhost'; 
$cfg['Servers'][$i]['port'] = ''; 
$cfg['Servers'][$i]['socket'] = ''; 
$cfg['Servers'][$i]['connect_type'] = 'tcp'; 
$cfg['Servers'][$i]['extension'] = 'mysqli'; 
$cfg['Servers'][$i]['auth_type'] = 'config'; 
$cfg['Servers'][$i]['user'] = 'root'; 
$cfg['Servers'][$i]['password'] = ''; 
$cfg['Servers'][$i]['AllowNoPassword'] = true; 

不知道該怎麼做,如果我嘗試加載mySQL控制檯我也需要使用密碼,我不知道如何解決。即使我重新安裝程序,我也會遇到同樣的錯誤。

回答

-1

Wamp通常沒有MySQL密碼。 嘗試replacinng C:/wampdirectory/apps/phpmyadmin-versionthing/config.inc.php,與此版本: (只需刪除當前文件的全部內容

<?php 
$cfg['blowfish_secret'] = 'a8b7c6d'; 
$i = 0; 
$i++; 
$cfg['Servers'][$i]['auth_type'] = 'cookie'; 
$cfg['Servers'][$i]['host'] = 'localhost'; 
$cfg['Servers'][$i]['connect_type'] = 'tcp'; 
$cfg['Servers'][$i]['compress'] = false; 
$cfg['Servers'][$i]['extension'] = 'mysqli'; 
$cfg['Servers'][$i]['AllowNoPassword'] = true; 
$cfg['UploadDir'] = ''; 
$cfg['SaveDir'] = ''; 

>

+1

?仍然得到相同的錯誤。 – germainelol

相關問題