MySQL/php assistance required...Please!
I am using a WAMP installation, with phpdev, I have not set any MySQL username and MySQL password while installing. However I created a file with the following code:
<?
$user="ramsys";
$password="ramsys";
$database="clients";
mysql_connect(localhost,$user,$password);
@mysql_select_db($database) or die( "Unable to select database");
$query="CREATE TABLE contacts (id int(6) NOT NULL auto_increment,first varchar(15) NOT NULL,last varchar(15) NOT NULL,phone varchar(20) NOT NULL,mobile varchar(20) NOT NULL,fax varchar(20) NOT NULL,email varchar(30) NOT NULL,web varchar(30) NOT NULL,PRIMARY KEY (id),UNIQUE id (id),KEY id_2 (id))";
mysql_query($query);
mysql_close();
?>
However when I run into at http://localhost/demo/ I get the following error.
Warning: Access denied for user: 'ramsys@127.0.0.1' (Using password: YES) in c:\phpdev\www\demo\index.php on line 5
Warning: MySQL Connection Failed: Access denied for user: 'ramsys@127.0.0.1' (Using password: YES) in c:\phpdev\www\demo\index.php on line 5
Unable to select database
Kindly advise how I can set the username and password for MySQL in a phpdev installation. However I am able to create tables using http://localhost/phpmyadmin/
Thanks for your time in advance....