If you are not registered or logged in, you may still use these forums but with limited features. Show recent topics
  [Search] Search   [Hottest Topics] Hottest Topics   [Members]  Member Listing   [FAQ]  FAQ 
[Register] Register / 
[Login] Login 
$POLLDB visibility (Advanced Poll 2.03)  XML
Forum Index » Support Forum
Author Message
cdonner
Newbie

Joined: 24/03/2006 03:27:53
Messages: 2
Offline

mysql_connect(): Access denied for user: 'cdonner@localhost' (Using password: NO) in /home/cdonner/public_html/cdonner/polls/include/class_mysql.php on line 34

The admin interface works (which uses the same config file, so don't give me crap about not using the correct database credentials like some of the poor souls who posted here earlier). I am using MySQL and as you can see from the error message, the correct database interface got involved. Save to say that my include path is correct as well. The funny thing is, when I inspect the value of the user id and password in booth.php, they are correct, but in class_mysql.php they have no value. It looks like the global $POLLDB is not known inside of class_mysql.php. I don't program PHP and don't really know the language, but could it be that the construct with this global array is not working as intended under certain circumstances/environments? PHP version is 4.3.10.
Carbonize
Master
[Avatar]

Joined: 12/06/2003 19:26:08
Messages: 4292
Location: Bristol, UK
Offline

The message is quite clear. It is saying the login information provided is incorrect. Check your username and password.

Carbonize
I am not the maker of the Advanced Guestbook

get Lazarus
[Email] [WWW] [Yahoo!] aim icon [MSN] [ICQ]
Auron
Expert
[Avatar]

Joined: 23/06/2003 22:02:17
Messages: 1053
Offline

admin panel and mysql do NOT use the same password btw.

Visit my site @ www.ragnaru.com
Adv. Poll Install Guide NOW BACK ONLINE! (And also rather out of date I would of thought)
[Email] [WWW]
cdonner
Newbie

Joined: 24/03/2006 03:27:53
Messages: 2
Offline

I am asking if there could be a problem with the code - I really don't feel like becoming an PHP expert in order to get this working.
I manually created the MySQL account and I KNOW what the correct password is, and the correct password is in the config file. The fact that the admin interface works PROVES this because the admin interface also has to connect to the database in order to function, and I know that it pulls in the same config file because it writes my traces to the screen.
What I am saying is that I inspected - by using output statements - the value of the user id and password fields of the $POLLDB array, or object, or whatever it is, and they are EMPTY in the method that uses the values to open a database connection. Somehow the global variable $POLLDB is not visible inside this method. All I am asking is that someone who understands PHP better than I take a look at this if there is an easy explanation for this behavior. Thanks.
Auron
Expert
[Avatar]

Joined: 23/06/2003 22:02:17
Messages: 1053
Offline

u need to fill in ur db details in the config file.

by the looks of things ur db DOES REQUIRE a password.

Visit my site @ www.ragnaru.com
Adv. Poll Install Guide NOW BACK ONLINE! (And also rather out of date I would of thought)
[Email] [WWW]
 
Forum Index » Support Forum
Go to:   
Based on the open source JForum