2013-07-15 120 views
0

我正在使用phpmyadmin 3.3.9的遗留系统,而我对config.inc.php文件做的所有操作都是将$cfg['Servers'][$i]['AllowNoPassword'] = true;更改为false 。接下来的事情我知道,我得到这个错误:phpmyadmin改变3.3.9配置文件没有给我访问phpmyadmin

MySQL said: 
Cannot connect: invalid settings. 
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. 

然后我试图恢复,但不管我做什么,它不连接。我用一个镜像系统的配置文件替换了配置文件,但没有运气!这是配置文件的内容,出了什么问题?

<?php 

/* Servers configuration */ 
$i = 0; 

/* 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; 

/* End of servers configuration */ 

$cfg['DefaultLang'] = 'en-utf-8'; 
$cfg['ServerDefault'] = 1; 
$cfg['UploadDir'] = ''; 
$cfg['SaveDir'] = ''; 


/* rajk - for blobstreaming */ 
$cfg['Servers'][$i]['bs_garbage_threshold'] = 50; 
$cfg['Servers'][$i]['bs_repository_threshold'] = '32M'; 
$cfg['Servers'][$i]['bs_temp_blob_timeout'] = 600; 
$cfg['Servers'][$i]['bs_temp_log_threshold'] = '32M'; 


?> 

该应用程序能够访问mysql罚款,问题是在访问phpmyadmin的Web界面。

我几乎觉得这是类似于如何在Windows和UNIX编辑的文件可能只在换行符的差异,因为问题的错误,因为我所做的就是换一个词,并保存它。但我完全在Windows中工作。

我试着从config改为auth_typehttp,但是没有运气。

回答

0

好吧,我刚刚重启,所有WAMP的服务,然后将它运行得很好!我想删除这个问题,但后来认为它可能对那些撕开头发但忘记重新启动的人有用。