I have a script that reports the following error:
Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'admin'@'localhost' (using password: YES) in C:\wamp\www\bits\includes\conne开发者_JAVA百科ct.inc.php on line 10
Notice: Undefined variable: l_error in C:\wamp\www\bits\includes\connect.inc.php on line 12
Notice: Undefined variable: l_cannotconnecttodatabase in C:\wamp\www\bits\includes\connect.inc.php on line 12
Why would this be?
Mysql user or password are incorrect. You need to set them in install script to correct values
It looks like you have the wrong password. Make sure mysql is installed and that whatever you are trying to install if configured to use the password you set for mysql.
It is impossible to give you a solution based on the information you supplied, but obviously you're trying to install a system that uses mysql and therefore requires credentials to be able to connect to the database management system.
You should refer to installation manual of the system in question to see where these credentials must be specified in order for installation to proceed.
EDIT: It appears that you will need to create a database and user before you can actually specify them for the bits script. You should have administrator password from the moment you installed mysql (or ask someone who did), and you can then use phpmyadmin to administer more databases and users. Keep in mind that the database user and all user accounts for your script will most likely be completely different. MySQL user to work with the database in its entirety, whereas user accounts are used to distinguish between the people accessing your scripts.
精彩评论