question about mysql user

Alles, was MySQL betrifft, kann hier besprochen werden.

question about mysql user

Postby yanghong » 21. July 2010 16:10

Hello, guys:

I am new for xampp and joomla. I am creating our website through mysql and joomla and xampp.

In mysql, I create a database for our usage. so in the webpage, I use php code to quary this database, but I don't want to use "root", I want to use some other user with read only premission. I create new user in mysql already. But when I access from webpages, it display the following result:

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'webread'@'localhost' (using password: NO) in D:\XAMPP\xampp\htdocs\Joomla15\components\com_php\files\dboperation.php on line 10
Server Unavailable

I don't know what is going on? anybody can help me?

Thank you in advance.
yanghong
 
Posts: 2
Joined: 21. July 2010 16:04

Re: question about mysql user

Postby Altrea » 21. July 2010 17:11

Does the user webread have a password?
Where do you have defined the permissions (global or table)?
i don't know, what kind of permissions Joomla needs. Maybe read only is not enough.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
free software according to purpose of usage
XAMPP 1.8 for local development/testing only
Zend Server 6 (free) for production environments
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 4523
Joined: 17. August 2009 13:05
XAMPP Version: 1.8.0
Operating System: W7Ux64

Re: question about mysql user

Postby yanghong » 21. July 2010 18:48

I add mysql user "webread" in datatable "user" of database "mysql". I couldn't setup pwd. By the way, I don't have pwd for "root" as well.
yanghong
 
Posts: 2
Joined: 21. July 2010 16:04

Re: question about mysql user

Postby Altrea » 22. July 2010 02:26

Don't add/edit/delete something in the mysql database on your own unless you know exactly what you are doing!
If you want to add a new user use phpmyadmin or the mysql functions for the command line.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
free software according to purpose of usage
XAMPP 1.8 for local development/testing only
Zend Server 6 (free) for production environments
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
It's like porn for programmers 8)
User avatar
Altrea
AF Moderator
 
Posts: 4523
Joined: 17. August 2009 13:05
XAMPP Version: 1.8.0
Operating System: W7Ux64


Return to MySQL

Who is online

Users browsing this forum: No registered users and 1 guest