Becki Posted February 27, 2006 Posted February 27, 2006 Hi, I just sat down to start installation of oscommerce. I am running on lmy ocal machine, I created a new database using phpmyadmin, but it did not ask for username password etc. I went into the privileges part and set a password and pressed 'go'. I then typed in a new username instead of 'root', I then pressed go and things have gone very downhill (which i'm not amused about). After pressing go I went straight to a 'Access denied' screen with following message: phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in config.inc.php and make sure that they correspond to the information given by the administrator of the MySQL server. Error MySQL said: Cannot connect: invalid settings. Was i supposed to enter a password while changing the username or something, I have gone into config.ini and can only find this part in the code: $cfg['SQLValidator']['use'] = FALSE; // Make the SQL Validator available $cfg['SQLValidator']['username'] = ''; // If you have a custom username, specify it here (defaults to anonymous) $cfg['SQLValidator']['password'] = ''; // Password for username I tried putting in the new username with the password and just root as the username but still access denied - am I changing the right thing. I was putting in the username like: $cfg['SQLValidator']['username'] = 'root'; Is this right? Please help as this is very frustrating! becki Also if i get past this I have a couple of questions regarding step 4 of the installation: Will the www address be http://localhost/ (I copied the files in catalog to htdoc) what is the Webserver root directory? HTTP cookie domain? Http cookie path? Many Thanks
Becki Posted February 28, 2006 Author Posted February 28, 2006 has anyone got any ideas, I can't do anything untill this is fixed!
spax Posted February 28, 2006 Posted February 28, 2006 In your config.inc.php file look for the instances of this: $cfg['Servers'][$i]['user'] = 'root'; // MySQL user $cfg['Servers'][$i]['password'] = ' '; // MySQL password (only needed with 'config' auth_type) That is where your username/password is set. Type in your password and it should work. You don't need to do anything to this part: $cfg['SQLValidator']['use'] = FALSE; // Make the SQL Validator available $cfg['SQLValidator']['username'] = ''; // If you have a custom username, specify it here (defaults to anonymous) $cfg['SQLValidator']['password'] = ''; // Password for username
Becki Posted February 28, 2006 Author Posted February 28, 2006 hi and thanks Do I put the password and username i tried to associate to my newly correctly database or the password and username i set up when installing the mysql server. For future reference do these need to be the same? Thanks
♥Vger Posted February 28, 2006 Posted February 28, 2006 Try both the old and the new. One set should work. Vger
Becki Posted February 28, 2006 Author Posted February 28, 2006 Thanks everyone - got it working again with the default username and my password, still not sure why the new username dosn't work but as long as it works i'm not complaining. Thankyou
Recommended Posts
Archived
This topic is now archived and is closed to further replies.