Hello all. I’m writing today because I’ve got a bit of a problem, and I was hoping your collective brains could help me find where I’ve gone wrong.
I’m working on a MySQL/PHP based website, to see if I can get beyond the "hello world" stage of my php programming, and my first main obstacle is in my database connection. Before I get to the problem, here’s my tech setup/info:
which then feeds into the following php:
When I try to view the page, I get an error saying:
where line 7 is
If, however, I set the config file to
it connects without any problem.
Any idea why this is happening? Or even better, how to fix it? I’ve tried giving rie_admin global privileges, with no change in the error. My Google-fu has also failed me. I know I could just keep developing using the root/no password setup, but as this is supposed to be more of an educational/mastering-php/mysql kind of thing, I thought it better to learn what’s going on.
Thanks in advance for any help.
P.S., as this is my first post, and I hope to be a contributor as well as a help seeker on this forum, I thought it appropriate to introduce myself. Hi. My name’s Warren.
I’m afraid I don’t have any particular answers for you =(. That stuff confuses me too. I do know that that kind of stuff is precicely why I don’t use MAMP (or any of the others) to develop locally. There is too much confusing when then trying to move it live. I’m sure smarter people than us laugh, but whatever. If I develop online, on the same server the real site will be on, I know I won’t have any problems.
Hi Warren, sounds like a real tough one. Only thing I can suggest is to (using mysql console):
There should be a minimum of GRANT USAGE and also a grant on the specific database. This might at least give you some insight as to why it’s not working.
Hope that at least points you in the right direction.
You must be logged in to reply to this topic.