PDA

View Full Version : PHP can't communicate w/ MySQL



Snowflake
5th June 2006, 09:07 PM
I'm trying to get a program that i am running on my webserver to work but i'm coming up with an error that says:

PHP has not been properly configured with the MySQL extension so that it can communicate with MySQL. Please check your php.ini file or recompile PHP.

I saw where someone suggested that you yum php-mysql and I did that but all i did was come up with a bunch of errors. I'm a newbie at this so details are appreciated! Thanks in advance!

wdgiles
6th June 2006, 02:51 AM
Can you post the contents of the errors so we can help figure out what's wrong?

Firewing1
6th June 2006, 02:55 AM
Try this:

yum update
yum install php mysql mysql-server php-mysql
reboot
Now it should work :)
Firewing1

Snowflake
6th June 2006, 03:31 AM
I just tried the thing that Firewing1 told me to do and all i got was a bunch of parser errors and finally an error about importing repond.xml from updates-released.

In my first post I wrote what the error said. The program i'm trying to work on is Moodle and that's what came up on the instalation php page.

Also I tried installing phpMyAdmin to maybe fix the problem and when it said to go to my webpage with the proper extension all I got was this error:

phpMyAdmin - Error
Cannot load mysql extension. Please check your PHP configuration. -Documentaion

I checked out the documentation but it didn't help me. Thanks for helping me!

JordanN
6th June 2006, 06:10 AM
Did you run yum as root?

Also, try doing a "yum clean all".

Snowflake
6th June 2006, 02:54 PM
I think it might be working now. I ran yum update again and then the other stuff and i think it's acting right now. Thanks for all your help

sirkali
21st July 2006, 04:31 AM
thanks for your solution "Firewing1",

I am using fedora core 4 and I encountered the above mentioned error msg and it worked great after a reboot.