PDA

View Full Version : How to configure PHP with MySQL ????


lipp9000
22nd July 2006, 13:37
I am running Fedora core 5 and have followed the howtoforge fedora core 5 perfect setup for ispconfig. MySQL and php are all setup and working, but I have phpBB on one of my users and I have created a database for this.

When I fill out the install page and fill out all the necessary fields and click install I get this error.

"The PHP configuration on your server doesn't support the database type that you chose."

Is PHP configured with MySQL by default? Or is there some line of code that needs to be added to the php config to enable it to work with mysql. One again I have followed the howtoforge perfect FD5 setup guide and havnt missed a thing, but it didnt say anything about configuring php with mysql.

Any suggestions?

Thanks in advance :)

TheRudy
22nd July 2006, 14:25
You using PHP5? PHP5 doesn't come with mysql library anymore so you'll have to activate it manually, if you don't, it won't work.. They removed mysql from official php5 package cause of some license problems i think.. Or simply use PHP4 instead :)

lipp9000
22nd July 2006, 14:37
its PHP5, so what do i need to do in order to get MySQL working then?

TheRudy
22nd July 2006, 14:47
Oh wait :D you already installed php-mysql cause you followed that guide.. erm, you can still check if you really have it installed.. Don't know the command for fedora, probaby yum, so yum install php-mysql and it should report if you have the latest version on it or not..

Try by enabling mysql extension in php.ini, can't hurt to try it, don't forget to restart apache afterwards!

falko
24th July 2006, 00:00
Do you have something like extension=mysql.so in your php.ini?

lipp9000
24th July 2006, 06:46
I fixed it. Thanks anyway. I installed this module called php-mysql, its php5 with mysql support already built in. Then it worked :D

falko
25th July 2006, 14:22
I installed this module called php-mysql, its php5 with mysql support already built in. Then it worked :D
Then you didn't follow the Perfect Setup close enough because that package is installed in chapter 10 on http://www.howtoforge.com/perfect_setup_fedora_core_5_p5 :

yum install php php-devel php-gd php-imap php-ldap php-mysql php-odbc php-pear php-xml php-xmlrpc curl curl-devel perl-libwww-perl ImageMagick libxml2 libxml2-devel;)

sniffffer
20th November 2009, 12:34
yum install php php-devel php-gd php-imap php-ldap php-mysql php-odbc php-pear php-xml php-xmlrpc curl curl-devel perl-libwww-perl ImageMagick libxml2 libxml2-devel

try that. ots perfect ... i simply wasted time without installing those packages, by the way i 'am a nood here. still pushing.

I was having the problem like this.:

I installed latest versions Mysql, php, apache on centos.
I am having a working project which is working perfectly on a wamp server. So i decided to try it on a lamp server. I installed centos five and also installed the packages available with that. My first assumptions went compleatly wrong when i tried those php over http. It was not working. Even it dosent give any error messages. I was blindly trying every single step to reintalling those packages again and again. How stupid. !! :o:eek::o:eek::o:eek::o

falko ooooooo thanks man.... :D