Page 1 of 1

[SOLVED] PHP5 and MySQL 4 not playing nice

Posted: Tue Jul 20, 2004 12:17 pm
by steedvlx
Hello,

It's been a while. But, I have another question for all youse.

I just configured a new XP server box, installed Apache2, MySQL4, and PHP5.

My localhost shows the following;
Apache/2.0.50 (Win32) PHP/5.0.0 Server at localhost Port 80
At least I know that Apache and PHP are working well enough to get this far. :)

On installing MySQL, there were no problems. I set it up as a service and used mysqld to initialize the root databases. Once again, no errors.

Then, I optimistically install phpmyadmin. When I try to access it, I get this;
cannot load MySQL extension,
please check PHP Configuration.
I check the documentation AND my PHP.ini for the problem. The file php_mysql.dll is exactly where the extensions directive says it is. I have played around until I'm blue in the face. And, I cannot clear this error.

I checked the PHP site, and it said that MySQL support is no longer "bundled". But, I thought I had it enabled it by loading the dll. nowhere can I find out how to load the libraries properly or even where to find them (isn't the dll the libraries?). Not even the installation docs mention this issue.

I would appreciate it if someone could point me to a good source on how I can solve this problem and get MySQL4 working with PHP5. I could always drop back to PHP4 I guess, but I want this server to be up-to-date as possible.

Thanks for anything you have on this subject.

Posted: Tue Jul 20, 2004 12:21 pm
by feyd
This is more a server set up problem...

Posted: Tue Jul 20, 2004 10:50 pm
by steedvlx
Does that mean I've posted in the wrong place or what? If so, would you kindly refer me to the proper place?

I've seen several similar setup problems here which is why I posted. I apologize if I am in error.

Otherwise, can anyone help me with this problem? It's driving me crazy.

Posted: Tue Jul 20, 2004 10:56 pm
by feyd
I moved the thread already..

Posted: Tue Jul 20, 2004 11:32 pm
by nigma
I had the similar troubles when configuring apache2 / php5 (with mysql extension).

my problem was that once i'd configured php.ini to use the mysql extension i'd forgotten to also copy libmysql.dll to %SYSTEMROOT%

Posted: Wed Jul 21, 2004 1:45 am
by steedvlx
nigma,

Thanks for the idea. But, I corrected that when I found another post here describing a similar problem that was resolved in this way.

I really thought I had found the answer. But, the same old problem still pops up. :(

[SOLVED] PHP5 and MySQL 4 not playing nice

Posted: Wed Jul 21, 2004 8:37 am
by steedvlx
Yeah well, sometimes the bear gets you and sometimes you get the bear.

A combination of factors combined to make this situation the headache that it was. First was reading instructions several times and thinking I did exactly what it said, only to realize that I did what I THOUGHT it said

1) Copying the PHP.ini to the %SYSTEM_ROOT% (according to the instructions.) Well, I thought that was `system32`. Another set of instructions explicitly said C:\WINDOWS. So, mistake number one.

2) PhpMyAdmin... Made the bonehead mistake of saving the conf file from notepad. So, when I looked at conf.inc.php. Of course it was where it was supposed to be. But, so was another mystery file called conf.inc.php.txt :oops:

Beware! be a very wary bear. :)

Thanks again,

Posted: Wed Jul 21, 2004 10:12 am
by nigma
glad you worked things out :)